summaryrefslogtreecommitdiffstats
path: root/libdimension-python
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@gmail.com>2011-09-22 19:06:57 -0400
committerTavian Barnes <tavianator@gmail.com>2011-09-22 19:06:57 -0400
commit5f46020e7090e28495d2b7e66e58f2c74698917a (patch)
treea2f5cfba9aa25024e176e8f05274e80a09aef4e4 /libdimension-python
parenta09085f36ac82886ba768ab141361c2e94c6ff5e (diff)
downloaddimension-5f46020e7090e28495d2b7e66e58f2c74698917a.tar.xz
Use double rather than single quotes for Python strings.
Diffstat (limited to 'libdimension-python')
-rwxr-xr-xlibdimension-python/tests/canvas.py2
-rwxr-xr-xlibdimension-python/tests/color.py8
-rwxr-xr-xlibdimension-python/tests/demo.py2
-rwxr-xr-xlibdimension-python/tests/geometry.py18
4 files changed, 15 insertions, 15 deletions
diff --git a/libdimension-python/tests/canvas.py b/libdimension-python/tests/canvas.py
index 239a548..0f07d66 100755
--- a/libdimension-python/tests/canvas.py
+++ b/libdimension-python/tests/canvas.py
@@ -51,7 +51,7 @@ except OSError as e:
canvas.clear(Blue)
if have_PNG:
- canvas.write_PNG('png.png')
+ canvas.write_PNG("png.png")
#if haveGL:
# canvas.drawGL()
diff --git a/libdimension-python/tests/color.py b/libdimension-python/tests/color.py
index 363aa0d..88e0b42 100755
--- a/libdimension-python/tests/color.py
+++ b/libdimension-python/tests/color.py
@@ -25,9 +25,9 @@ from dimension import *
die_on_warnings(True)
c = Color(0, 0.5, 1, trans = 0.5, filter = 0.35)
-assert repr(c) == 'dimension.Color(0.0, 0.5, 1.0, 0.5, 0.35)', repr(c)
-assert str(c) == '<red = 0.0, green = 0.5, blue = 1.0, \
-trans = 0.5, filter = 0.35>', str(c)
+assert repr(c) == "dimension.Color(0.0, 0.5, 1.0, 0.5, 0.35)", repr(c)
+assert str(c) == "<red = 0.0, green = 0.5, blue = 1.0, \
+trans = 0.5, filter = 0.35>", str(c)
assert c.red == 0, c.red
assert c.green == 0.5, c.green
assert c.blue == 1, c.blue
@@ -35,7 +35,7 @@ assert c.trans == 0.5, c.filter
assert c.filter == 0.35, c.trans
c = Color(1, 0.5, 0)
-assert str(c) == '<red = 1.0, green = 0.5, blue = 0.0>', str(c)
+assert str(c) == "<red = 1.0, green = 0.5, blue = 0.0>", str(c)
assert Black == Color(0, 0, 0), Black
assert White == Color(1, 1, 1), White
diff --git a/libdimension-python/tests/demo.py b/libdimension-python/tests/demo.py
index a9774bc..720a96c 100755
--- a/libdimension-python/tests/demo.py
+++ b/libdimension-python/tests/demo.py
@@ -56,4 +56,4 @@ scene.recursion_limit = 5
scene.raytrace()
if have_PNG:
- canvas.write_PNG('demo.png')
+ canvas.write_PNG("demo.png")
diff --git a/libdimension-python/tests/geometry.py b/libdimension-python/tests/geometry.py
index cf9cb41..dddd4ea 100755
--- a/libdimension-python/tests/geometry.py
+++ b/libdimension-python/tests/geometry.py
@@ -37,8 +37,8 @@ v = Vector(1.5, 2.5, 3.5)
assert v.x == 1.5, v.x
assert v.y == 2.5, v.y
assert v.z == 3.5, v.z
-assert repr(v) == 'dimension.Vector(1.5, 2.5, 3.5)', repr(v)
-assert str(v) == '<1.5, 2.5, 3.5>', str(v)
+assert repr(v) == "dimension.Vector(1.5, 2.5, 3.5)", repr(v)
+assert str(v) == "<1.5, 2.5, 3.5>", str(v)
v = Vector(x = 2, y = 3, z = 6)
@@ -58,13 +58,13 @@ m = Matrix(1, 2, 3, 4,
5, 6, 7, 8,
9, 10, 11, 12)
-assert repr(m) == 'dimension.Matrix(1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, \
-9.0, 10.0, 11.0, 12.0)', repr(m)
-assert str(m) == '\n' \
- '[1.0\t2.0\t3.0\t4.0]\n' \
- '[5.0\t6.0\t7.0\t8.0]\n' \
- '[9.0\t10.0\t11.0\t12.0]\n' \
- '[0.0\t0.0\t0.0\t1.0]', str(m)
+assert repr(m) == "dimension.Matrix(1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, \
+9.0, 10.0, 11.0, 12.0)", repr(m)
+assert str(m) == "\n" \
+ "[1.0\t2.0\t3.0\t4.0]\n" \
+ "[5.0\t6.0\t7.0\t8.0]\n" \
+ "[9.0\t10.0\t11.0\t12.0]\n" \
+ "[0.0\t0.0\t0.0\t1.0]", str(m)
s = scale(0.5)
assert s == Matrix(0.5, 0, 0, 0,