Skip to content

Commit

Permalink
more testing
Browse files Browse the repository at this point in the history
Signed-off-by: Ian Chen <ichen@openrobotics.org>
  • Loading branch information
iche033 committed Aug 17, 2023
1 parent 16cf100 commit 2aa1cd5
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
1 change: 1 addition & 0 deletions src/plugins/minimal_scene/MinimalScene.cc
Original file line number Diff line number Diff line change
Expand Up @@ -691,6 +691,7 @@ void GzRenderer::Destroy()
// clean up in the rendering thread
this->dataPtr->camera.reset();
this->dataPtr->rayQuery.reset();
std::cerr << "================ GzRenderer Destroy " << std::endl;
}

/////////////////////////////////////////////////
Expand Down
11 changes: 6 additions & 5 deletions test/integration/minimal_scene.cc
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ TEST(MinimalSceneTest, GZ_UTILS_TEST_ENABLED_ONLY_ON_LINUX(Config))
std::cerr << " =================== after get render engine " << std::endl;
ASSERT_NE(nullptr, engine);

EXPECT_EQ(1u, engine->SceneCount());
/* EXPECT_EQ(1u, engine->SceneCount());
auto scene = engine->SceneByName("banana");
ASSERT_NE(nullptr, scene);
Expand All @@ -139,7 +139,7 @@ TEST(MinimalSceneTest, GZ_UTILS_TEST_ENABLED_ONLY_ON_LINUX(Config))
EXPECT_EQ(rendering::CameraProjectionType::CPT_ORTHOGRAPHIC,
camera->ProjectionType());

*/
// Cleanup
auto plugins = win->findChildren<Plugin *>();
EXPECT_EQ(2, plugins.size());
Expand All @@ -148,11 +148,12 @@ TEST(MinimalSceneTest, GZ_UTILS_TEST_ENABLED_ONLY_ON_LINUX(Config))
EXPECT_TRUE(app.RemovePlugin(pluginName));
plugins.clear();


win->QuickWindow()->close();

camera.reset();
std::cerr << " =================== before destroying scene" << std::endl;
engine->DestroyScene(scene);
// camera.reset();
// std::cerr << " =================== before destroying scene" << std::endl;
// engine->DestroyScene(scene);

std::cerr << " =================== before unloading engine " << std::endl;
EXPECT_TRUE(rendering::unloadEngine(engine->Name()));
Expand Down

0 comments on commit 2aa1cd5

Please sign in to comment.