void TestDefaultPipeLine::checkDefaultPipelineWithMissingIntersection() { EXPECT_MSG_EMIT(Warning) ; EXPECT_MSG_NOEMIT(Error) ; std::stringstream scene ; scene << "<?xml version='1.0'?> \n" "<Node name='Root' gravity='0 -9.81 0' time='0' animate='0' > \n" " <DefaultPipeline name='pipeline'/> \n" "</Node> \n" ; Node::SPtr root = SceneLoaderXML::loadFromMemory ("testscene", scene.str().c_str(), scene.str().size()) ; ASSERT_NE(root.get(), nullptr) ; root->init(ExecParams::defaultInstance()) ; BaseObject* clp = root->getObject("pipeline") ; ASSERT_NE(clp, nullptr) ; clearSceneGraph(); }
int TestDefaultPipeLine::checkDefaultPipelineWithMonkeyValueForDepth(int dvalue) { std::stringstream scene ; scene << "<?xml version='1.0'?> \n" "<Node name='Root' gravity='0 -9.81 0' time='0' animate='0' > \n" " <DefaultPipeline name='pipeline' depth='"<< dvalue <<"'/> \n" " <DiscreteIntersection name='interaction'/> \n" "</Node> \n" ; Node::SPtr root = SceneLoaderXML::loadFromMemory ("testscene", scene.str().c_str(), scene.str().size()) ; //EXPECT_NE( (root.get()), NULL) ; root->init(ExecParams::defaultInstance()) ; DefaultPipeline* clp = dynamic_cast<DefaultPipeline*>(root->getObject("pipeline")) ; //ASSERT_NE( (clp), nullptr) ; int rv = clp->d_depth.getValue() ; clearSceneGraph(); return rv; }
BaseSofa_test::~BaseSofa_test() { clearSceneGraph(); }