This file is indexed.

/usr/lib/python2.7/dist-packages/dicom/test/test_UID.py is in python-dicom 0.9.7-1.1ubuntu1.

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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# test_UID.py
"""Test suite for UID.py"""
# Copyright (c) 2008 Darcy Mason
# This file is part of pydicom, released under a modified MIT license.
#    See the file license.txt included with this distribution, also
#    available at http://pydicom.googlecode.com

import unittest
from dicom.UID import UID

class UIDtests(unittest.TestCase):
    def testKnownUID(self):
        """UID: Known UID properties accessed....................."""
        uid = UID('1.2.840.10008.1.2') # Implicit VR Little Endian
        expected = 'Implicit VR Little Endian'
        got = uid.name
        self.assertEqual(got, expected, "UID: expected '%s', got '%s' for UID name" % (expected, got))
        
        expected = 'Transfer Syntax'
        got = uid.type
        self.assertEqual(got, expected, "UID: expected '%s', got '%s' for UID type" % (expected, got))
        
        expected = 'Default Transfer Syntax for DICOM'
        got = uid.info
        self.assertEqual(got, expected, "UID: expected '%s', got '%s' for UID info" % (expected, got))
        
        expected = False
        got = uid.is_retired
        self.assertEqual(got, expected, "UID: expected '%s', got '%s' for UID is_retired" % (expected, got))
    def testComparison(self):
        """UID: can compare by number or by name.................."""
        uid = UID('1.2.840.10008.1.2')
        self.assertEqual(uid, 'Implicit VR Little Endian', "UID equality failed on name")
        self.assertEqual(uid, '1.2.840.10008.1.2', "UID equality failed on number string")
    def testCompareNumber(self):
        """UID: comparing against a number give False............."""
        # From issue 96
        uid = UID('1.2.3')
        self.assertNotEqual(uid, 3, "Comparison against a number returned True")
    def testCompareNone(self):
        """UID: comparing against None give False................."""
        # From issue 96
        uid = UID('1.2.3')
        self.assertNotEqual(uid, None, "Comparison against a number returned True")
    def testTransferSyntaxes(self):
        pass
        
        
if __name__ == "__main__":
    unittest.main()