[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [28846] branches/soc-2010-leifandersen/ tests: The code will compile now, but not because it actually works, only because I have commented out that portion of the Cmake Scripts.

Leif Andersen leif.a.andersen at gmail.com
Wed May 19 04:03:31 CEST 2010


Revision: 28846
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=28846
Author:   leifandersen
Date:     2010-05-19 04:03:29 +0200 (Wed, 19 May 2010)

Log Message:
-----------
The code will compile now, but not because it actually works, only because I have commented out that portion of the Cmake Scripts.  Also added a token unittest written with pyunit based on the rna test found in release/test.  Also began to add a means for allowing other people to add their own unit tests in python.  It's still very much a hack, as not only does it require the user to be using a UNIX based OS, but they must also have a file structure identical to mine, written in test/pyunit/runtests.c; the final script will likely be written in CTest though, if at all possible anyway.

Modified Paths:
--------------
    branches/soc-2010-leifandersen/tests/CMakeLists.txt
    branches/soc-2010-leifandersen/tests/gtest/CMakeLists.txt
    branches/soc-2010-leifandersen/tests/gtest/firsttest.cpp
    branches/soc-2010-leifandersen/tests/pyunit/CMakeLists.txt

Added Paths:
-----------
    branches/soc-2010-leifandersen/tests/pyunit/app/
    branches/soc-2010-leifandersen/tests/pyunit/context/
    branches/soc-2010-leifandersen/tests/pyunit/data/
    branches/soc-2010-leifandersen/tests/pyunit/ops/
    branches/soc-2010-leifandersen/tests/pyunit/props/
    branches/soc-2010-leifandersen/tests/pyunit/types/
    branches/soc-2010-leifandersen/tests/pyunit/utils/

Modified: branches/soc-2010-leifandersen/tests/CMakeLists.txt
===================================================================
--- branches/soc-2010-leifandersen/tests/CMakeLists.txt	2010-05-19 01:42:17 UTC (rev 28845)
+++ branches/soc-2010-leifandersen/tests/CMakeLists.txt	2010-05-19 02:03:29 UTC (rev 28846)
@@ -1,2 +1,4 @@
-add_subdirectory(gtest)
+ENABLE_TESTING()
+
+#add_subdirectory(gtest)
 add_subdirectory(pyunit)

Modified: branches/soc-2010-leifandersen/tests/gtest/CMakeLists.txt
===================================================================
--- branches/soc-2010-leifandersen/tests/gtest/CMakeLists.txt	2010-05-19 01:42:17 UTC (rev 28845)
+++ branches/soc-2010-leifandersen/tests/gtest/CMakeLists.txt	2010-05-19 02:03:29 UTC (rev 28846)
@@ -12,8 +12,8 @@
 
 # cxx_executable(name dir lib srcs...)
 # cxx_executable_with_flags(name cxx_flags lib srcs...)
-cxx_executable_with_flags(
-  firsttest "${cxx_default}" gtest_main "firsttest.cpp" ${ARGN})
+#cxx_executable_with_flags(
+#  firsttest "${cxx_default}" gtest_main "firsttest.cpp" ${ARGN})
 
 #------------------------------------------
 
@@ -54,7 +54,7 @@
 BLENDERLIB(bf_blenkernel_tests "${SRC}" "${INC}")
 
 
-SETUP_LIBLINKS(firsttest)
+#SETUP_LIBLINKS(firsttest)
 #------------------------
 # Other tests I'm doing
 
@@ -133,7 +133,7 @@
 
 add_executable(secondtest secondtest.c)
 
-ADD_DEPENDENCIES(secondtest blender makesdna)
+ADD_DEPENDENCIES(secondtest blender makesdna4)
 
 TARGET_LINK_LIBRARIES(secondtest ${BLENDER_SORTED_LIBS})
 

Modified: branches/soc-2010-leifandersen/tests/gtest/firsttest.cpp
===================================================================
--- branches/soc-2010-leifandersen/tests/gtest/firsttest.cpp	2010-05-19 01:42:17 UTC (rev 28845)
+++ branches/soc-2010-leifandersen/tests/gtest/firsttest.cpp	2010-05-19 02:03:29 UTC (rev 28846)
@@ -1,4 +1,4 @@
-#include <gtest/gtest.h>
+/*#include <gtest/gtest.h>
 extern "C" {
 	#include "BKE_bmesh.h"
 	
@@ -60,3 +60,4 @@
   ::testing::InitGoogleTest(&argc, argv);
   return RUN_ALL_TESTS();
 }
+*/

Modified: branches/soc-2010-leifandersen/tests/pyunit/CMakeLists.txt
===================================================================
--- branches/soc-2010-leifandersen/tests/pyunit/CMakeLists.txt	2010-05-19 01:42:17 UTC (rev 28845)
+++ branches/soc-2010-leifandersen/tests/pyunit/CMakeLists.txt	2010-05-19 02:03:29 UTC (rev 28846)
@@ -0,0 +1,9 @@
+add_subdirectory(app)
+add_subdirectory(context)
+add_subdirectory(data)
+add_subdirectory(ops)
+add_subdirectory(props)
+add_subdirectory(types)
+add_subdirectory(utils)
+add_executable(RunTests runtests.c)
+#add_test(testtesting blender -b -P leiftest.py)





More information about the Bf-blender-cvs mailing list