[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [29373] branches/soc-2010-leifandersen/ tests/gtest: A few more tests were played with, also, more gtest based tests were tried...but thusfar with little success, not much here, only commiting in preporation for a merge.
Leif Andersen
leif.a.andersen at gmail.com
Wed Jun 9 21:38:02 CEST 2010
Revision: 29373
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=29373
Author: leifandersen
Date: 2010-06-09 21:38:02 +0200 (Wed, 09 Jun 2010)
Log Message:
-----------
A few more tests were played with, also, more gtest based tests were tried...but thusfar with little success, not much here, only commiting in preporation for a merge.
Modified Paths:
--------------
branches/soc-2010-leifandersen/tests/gtest/CMakeLists.txt
branches/soc-2010-leifandersen/tests/gtest/secondtest.c
Added Paths:
-----------
branches/soc-2010-leifandersen/tests/gtest/editors/
branches/soc-2010-leifandersen/tests/gtest/editors/CMakeLists.txt
branches/soc-2010-leifandersen/tests/gtest/editors/physics/
branches/soc-2010-leifandersen/tests/gtest/editors/physics/CMakeLists.txt
branches/soc-2010-leifandersen/tests/gtest/editors/physics/particle_object_test.cpp
Modified: branches/soc-2010-leifandersen/tests/gtest/CMakeLists.txt
===================================================================
--- branches/soc-2010-leifandersen/tests/gtest/CMakeLists.txt 2010-06-09 19:31:10 UTC (rev 29372)
+++ branches/soc-2010-leifandersen/tests/gtest/CMakeLists.txt 2010-06-09 19:38:02 UTC (rev 29373)
@@ -27,6 +27,7 @@
CMAKE_POLICY(SET CMP0010 NEW)
ADD_SUBDIRECTORY(blenlib)
+ADD_SUBDIRECTORY(editors)
# For Google Test
# Where gtest's .h files can be found.
@@ -59,6 +60,8 @@
${Blender_SOURCE_DIR}/source/kernel/gen_messaging
${Blender_SOURCE_DIR}/source/kernel/gen_system
${Blender_SOURCE_DIR}/extern/glew/include
+
+ ${Blender_SOURCE_DIR}/source/blender/editors
)
IF(WIN32)
@@ -95,7 +98,10 @@
ENDIF(CMAKE_SYSTEM_NAME MATCHES "Linux")
# Setup the exe sources and buildinfo
-SET(EXESRC blendertests.cpp teststubs.c sampletest.cpp blenlib/BLI_math_base_test.cpp)
+SET(EXESRC blendertests.cpp
+ teststubs.c sampletest.cpp
+ blenlib/BLI_math_base_test.cpp
+ editors/physics/particle_object_test)
IF(WIN32)
SET(EXESRC ${EXESRC} ${Blender_SOURCE_DIR}/source/icons/winblender.rc)
Added: branches/soc-2010-leifandersen/tests/gtest/editors/CMakeLists.txt
===================================================================
--- branches/soc-2010-leifandersen/tests/gtest/editors/CMakeLists.txt (rev 0)
+++ branches/soc-2010-leifandersen/tests/gtest/editors/CMakeLists.txt 2010-06-09 19:38:02 UTC (rev 29373)
@@ -0,0 +1 @@
+ADD_SUBDIRECTORY(physics)
Added: branches/soc-2010-leifandersen/tests/gtest/editors/physics/CMakeLists.txt
===================================================================
Added: branches/soc-2010-leifandersen/tests/gtest/editors/physics/particle_object_test.cpp
===================================================================
--- branches/soc-2010-leifandersen/tests/gtest/editors/physics/particle_object_test.cpp (rev 0)
+++ branches/soc-2010-leifandersen/tests/gtest/editors/physics/particle_object_test.cpp 2010-06-09 19:38:02 UTC (rev 29373)
@@ -0,0 +1,24 @@
+#include <gtest/gtest.h>
+#include "BKE_global.h"
+#include "BKE_context.h"
+
+extern "C" {
+ #include "BKE_particle.h"
+ #include "physics/physics_intern.h"
+ #include "include/ED_particle.h"
+ #include "include/ED_physics.h"
+ #include "RNA_define.h"
+ #include "BLI_math_base.h"
+}
+
+
+TEST(PhysicsEditor, TestAdding) {
+// bContext *C= CTX_create();
+
+// C = CTX_create();
+// Scene *scene;
+// Object *ob;
+// char name[256] = "Name";
+
+// ModifierData *mod = object_add_particle_system(scene, ob, name);
+}
Modified: branches/soc-2010-leifandersen/tests/gtest/secondtest.c
===================================================================
--- branches/soc-2010-leifandersen/tests/gtest/secondtest.c 2010-06-09 19:31:10 UTC (rev 29372)
+++ branches/soc-2010-leifandersen/tests/gtest/secondtest.c 2010-06-09 19:38:02 UTC (rev 29373)
@@ -1,11 +1,6 @@
-#include <stdio.h>
-#include "BKE_bmesh.h"
+#include "BKE_context.h"
-
int main() {
- EditMesh bob;
- printf("Hello World!\n");
-
- BME_editmesh_to_bmesh(&bob);
+ bContext *C= CTX_create();
return 0;
}
More information about the Bf-blender-cvs
mailing list