[75997] trunk/dports/python/py27-pydicom
eborisch at macports.org
eborisch at macports.org
Tue Feb 15 07:15:51 PST 2011
Revision: 75997
http://trac.macports.org/changeset/75997
Author: eborisch at macports.org
Date: 2011-02-15 07:15:51 -0800 (Tue, 15 Feb 2011)
Log Message:
-----------
py27-pydicom: Update to include upstream patch
Modified Paths:
--------------
trunk/dports/python/py27-pydicom/Portfile
Added Paths:
-----------
trunk/dports/python/py27-pydicom/files/
trunk/dports/python/py27-pydicom/files/patch.dicom_UID.py
trunk/dports/python/py27-pydicom/files/patch.dicom_test__write_stds.py
trunk/dports/python/py27-pydicom/files/patch.dicom_test_test_UID.py
Modified: trunk/dports/python/py27-pydicom/Portfile
===================================================================
--- trunk/dports/python/py27-pydicom/Portfile 2011-02-15 15:12:22 UTC (rev 75996)
+++ trunk/dports/python/py27-pydicom/Portfile 2011-02-15 15:15:51 UTC (rev 75997)
@@ -6,6 +6,7 @@
name py27-pydicom
version 0.9.5
+revision 1
platforms darwin
categories python
maintainers eborisch \
@@ -27,4 +28,10 @@
sha1 cd8739c53e43b8ff2113debe70cea74e95340467 \
rmd160 d6f80a0fd632714359eb24b79b15a01aed16e570
+# Patches from upstream revision 156044badd:
+# See http://code.google.com/p/pydicom/issues/detail?id=96
+patchfiles patch.dicom_UID.py \
+ patch.dicom_test__write_stds.py \
+ patch.dicom_test_test_UID.py
+
depends_lib-append port:py27-numpy
Added: trunk/dports/python/py27-pydicom/files/patch.dicom_UID.py
===================================================================
--- trunk/dports/python/py27-pydicom/files/patch.dicom_UID.py (rev 0)
+++ trunk/dports/python/py27-pydicom/files/patch.dicom_UID.py 2011-02-15 15:15:51 UTC (rev 75997)
@@ -0,0 +1,14 @@
+--- dicom/UID.py.orig 2011-01-27 12:24:59.000000000 -0600
++++ dicom/UID.py 2011-01-27 12:25:37.000000000 -0600
+@@ -77,9 +77,9 @@
+
+ def __eq__(self, other):
+ """Override string equality so either name or UID number match passes"""
+- if str.__eq__(self, other):
++ if str.__eq__(self, other) is True: # 'is True' needed (issue 96)
+ return True
+- if str.__eq__(self.name, other):
++ if str.__eq__(self.name, other) is True: # 'is True' needed (issue 96)
+ return True
+ return False
+
Added: trunk/dports/python/py27-pydicom/files/patch.dicom_test__write_stds.py
===================================================================
--- trunk/dports/python/py27-pydicom/files/patch.dicom_test__write_stds.py (rev 0)
+++ trunk/dports/python/py27-pydicom/files/patch.dicom_test__write_stds.py 2011-02-15 15:15:51 UTC (rev 75997)
@@ -0,0 +1,11 @@
+--- dicom/test/_write_stds.py.orig 2011-02-15 09:07:21.000000000 -0600
++++ dicom/test/_write_stds.py 2011-02-15 09:07:37.000000000 -0600
+@@ -36,7 +36,7 @@
+ # Implicit VR, big endian, SQ's with defined lengths
+ # Realized after coding this that there is no Impl VR big endian in DICOM std;
+ # however, it seems to exist as a GE private transfer syntax.
+-# Will leave this here for now, but not test with it.
++# Will leave this here for now.
+ impl_BE_deflen_std_hex = (
+ "00 10 00 10 " # (0010, 0010) Patient's Name
+ "00 00 00 0c " # length 12
Added: trunk/dports/python/py27-pydicom/files/patch.dicom_test_test_UID.py
===================================================================
--- trunk/dports/python/py27-pydicom/files/patch.dicom_test_test_UID.py (rev 0)
+++ trunk/dports/python/py27-pydicom/files/patch.dicom_test_test_UID.py 2011-02-15 15:15:51 UTC (rev 75997)
@@ -0,0 +1,19 @@
+--- dicom/test/test_UID.py.orig 2011-01-27 12:23:41.000000000 -0600
++++ dicom/test/test_UID.py 2011-01-27 12:24:16.000000000 -0600
+@@ -32,6 +32,16 @@
+ 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
+
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20110215/3deb793e/attachment.html>
More information about the macports-changes
mailing list