[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [30992] branches/soc-2010-leifandersen: 1.
Leif Andersen
leif.a.andersen at gmail.com
Tue Aug 3 00:16:47 CEST 2010
Revision: 30992
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=30992
Author: leifandersen
Date: 2010-08-03 00:16:46 +0200 (Tue, 03 Aug 2010)
Log Message:
-----------
1. The tests now read the hashfile, although it seems that the hash code changes when it shouldn't.
2. Fixed my python scripts to match with the *new* way python operators are registered.
Modified Paths:
--------------
branches/soc-2010-leifandersen/release/scripts/op/tests_hash.py
branches/soc-2010-leifandersen/release/scripts/op/tests_render.py
branches/soc-2010-leifandersen/release/scripts/ui/space_tests.py
branches/soc-2010-leifandersen/tests/export_import_testing/export_import_testing.py
branches/soc-2010-leifandersen/tests/export_import_testing/hashfile.txt
Modified: branches/soc-2010-leifandersen/release/scripts/op/tests_hash.py
===================================================================
--- branches/soc-2010-leifandersen/release/scripts/op/tests_hash.py 2010-08-02 18:22:34 UTC (rev 30991)
+++ branches/soc-2010-leifandersen/release/scripts/op/tests_hash.py 2010-08-02 22:16:46 UTC (rev 30992)
@@ -135,13 +135,19 @@
TESTS_OT_read_hashfile,
]
+#def register():
+# for i in classes:
+# bpy.types.register(i)
+
+#def unregister():
+# for i in classes:
+# bpy.types.unregister(i)
+
def register():
- for i in classes:
- bpy.types.register(i)
+ pass
def unregister():
- for i in classes:
- bpy.types.unregister(i)
+ pass
if __name__ == "__main__":
register()
Modified: branches/soc-2010-leifandersen/release/scripts/op/tests_render.py
===================================================================
--- branches/soc-2010-leifandersen/release/scripts/op/tests_render.py 2010-08-02 18:22:34 UTC (rev 30991)
+++ branches/soc-2010-leifandersen/release/scripts/op/tests_render.py 2010-08-02 22:16:46 UTC (rev 30992)
@@ -123,13 +123,19 @@
TESTS_OT_anim_build,
]
+#def register():
+# for i in classes:
+# bpy.types.register(i)
+
+#def unregister():
+# for i in classes:
+# bpy.types.unregister(i)
+
def register():
- for i in classes:
- bpy.types.register(i)
+ pass
def unregister():
- for i in classes:
- bpy.types.unregister(i)
+ pass
if __name__ == "__main__":
register()
Modified: branches/soc-2010-leifandersen/release/scripts/ui/space_tests.py
===================================================================
--- branches/soc-2010-leifandersen/release/scripts/ui/space_tests.py 2010-08-02 18:22:34 UTC (rev 30991)
+++ branches/soc-2010-leifandersen/release/scripts/ui/space_tests.py 2010-08-02 22:16:46 UTC (rev 30992)
@@ -56,14 +56,20 @@
menu_func = (lambda self, context: self.layout.menu("INFO_MT_tests"))
+#def register():
+# for i in classes:
+# bpy.types.register(i)
+# bpy.types.INFO_HT_header.append(menu_func)
+
+#def unregister():
+# for i in classes:
+# bpy.types.unregister(i)
+
def register():
- for i in classes:
- bpy.types.register(i)
- bpy.types.INFO_HT_header.append(menu_func)
+ pass
def unregister():
- for i in classes:
- bpy.types.unregister(i)
+ pass
if __name__ == "__main__":
register()
Modified: branches/soc-2010-leifandersen/tests/export_import_testing/export_import_testing.py
===================================================================
--- branches/soc-2010-leifandersen/tests/export_import_testing/export_import_testing.py 2010-08-02 18:22:34 UTC (rev 30991)
+++ branches/soc-2010-leifandersen/tests/export_import_testing/export_import_testing.py 2010-08-02 22:16:46 UTC (rev 30992)
@@ -9,12 +9,16 @@
class TestCurrentFile(unittest.TestCase):
+ hash = 0
+
def setUp(self):
- pass
+ for hashpair in data:
+ if hashpair[0] == os.path.split(bpy.data.filepath)[1]:
+ self.hash = hashpair[1]
def test_all_quads(self):
bpy.ops.tests.hash()
- self.assertEquals(data[0][1], tests.hashfile.last_hash)
+ self.assertEquals(self.hash, tests.hashfile.last_hash)
def suite():
return unittest.TestSuite([
Modified: branches/soc-2010-leifandersen/tests/export_import_testing/hashfile.txt
===================================================================
--- branches/soc-2010-leifandersen/tests/export_import_testing/hashfile.txt 2010-08-02 18:22:34 UTC (rev 30991)
+++ branches/soc-2010-leifandersen/tests/export_import_testing/hashfile.txt 2010-08-02 22:16:46 UTC (rev 30992)
@@ -1 +1,7 @@
-all_quads = 4476784380650705631
+all_quads.blend = -18581593070168372584
+all_tris.blend = -23193331729858782021
+edges.blend = 4476784382546500577
+fgons.blend = -23193331727958294221
+mexed_quads_and_tris.blend = -13969959693018266161
+NURBS.blend = 4476784380650705631
+verticies.blend = 4476784380650705631
More information about the Bf-blender-cvs
mailing list