This file is indexed.

/usr/share/pyshared/matplotlib/tests/test_png.py is in python-matplotlib 1.1.1~rc1+git20120423-0ubuntu1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
from matplotlib.testing.decorators import image_comparison, knownfailureif
from matplotlib import pyplot as plt
import matplotlib.cm as cm
import glob
import os

@image_comparison(baseline_images=['pngsuite'], extensions=['png'])
def test_pngsuite():
    dirname = os.path.join(
        os.path.dirname(__file__),
        'baseline_images',
        'pngsuite')
    files = glob.glob(os.path.join(dirname, 'basn*.png'))
    files.sort()

    fig = plt.figure(figsize=(len(files), 2))

    for i, fname in enumerate(files):
        data = plt.imread(fname)
        cmap = None # use default colormap
        if data.ndim==2:
            # keep grayscale images gray
            cmap = cm.gray
        plt.imshow(data, extent=[i,i+1,0,1], cmap=cmap)

    plt.gca().get_frame().set_facecolor("#ddffff")
    plt.gca().set_xlim(0, len(files))