mirror of
https://github.com/KLayout/klayout.git
synced 2026-08-29 17:30:09 +02:00
Issue 771 (#773)
* Fixed the issue - Byte array variant was not properly converted to Python/Ruby objects. * Added tests + properly converting byte arrays to byte array variants in Python.
This commit is contained in:
Vendored
+7
@@ -1304,6 +1304,13 @@ class BasicTest(unittest.TestCase):
|
||||
self.assertEqual( str(b.b22c()), "hallo" )
|
||||
self.assertEqual( type(b.b22c()).__name__, "LayerInfo" )
|
||||
|
||||
# byte arrays through Variants
|
||||
if sys.version_info >= (3, 0):
|
||||
self.assertEqual( b.b22a( [ bytes('abc', 'utf-8') ] ), 1 )
|
||||
self.assertEqual( str(b.b22c()), "b'abc'" )
|
||||
self.assertEqual( str(b.b22d()), "b'abc'" )
|
||||
self.assertEqual( str(b.var()), "b'abc'" )
|
||||
|
||||
def test_23(self):
|
||||
|
||||
b = pya.B()
|
||||
|
||||
Reference in New Issue
Block a user