From 438e4c497d5a9f8e9fd75ea63fb05eac860c2708 Mon Sep 17 00:00:00 2001 From: Tavian Barnes Date: Wed, 15 Jun 2011 23:27:19 -0600 Subject: Make python module more "pythonic". Use lower_case instead of mixedCase, and add docstrings. --- libdimension-python/tests/geometry.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'libdimension-python/tests/geometry.py') diff --git a/libdimension-python/tests/geometry.py b/libdimension-python/tests/geometry.py index c1d4f48..e18d17a 100755 --- a/libdimension-python/tests/geometry.py +++ b/libdimension-python/tests/geometry.py @@ -22,7 +22,7 @@ from dimension import * # Treat warnings as errors for tests -dieOnWarnings(True) +die_on_warnings(True) assert 0 == Vector(0, 0, 0), Vector(0) assert X == Vector(1, 0, 0), X @@ -66,10 +66,10 @@ assert str(m) == '\n' \ '[9.0\t10.0\t11.0\t12.0]\n' \ '[0.0\t0.0\t0.0\t1.0]', str(m) -s = scale(Vector(1, 2, 3)) -assert s == Matrix(1, 0, 0, 0, - 0, 2, 0, 0, - 0, 0, 3, 0), s +s = scale(0.5) +assert s == Matrix(0.5, 0, 0, 0, + 0, 0.5, 0, 0, + 0, 0, 0.5, 0), s t = translate(1, 2, 3) assert t == Matrix(1, 0, 0, 1, -- cgit v1.2.3