Skip to content

Commit

Permalink
address PR comments
Browse files Browse the repository at this point in the history
  • Loading branch information
mattelser committed Oct 5, 2023
1 parent ed4a477 commit d4520ff
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 14 deletions.
6 changes: 5 additions & 1 deletion .vscode/launch.linux.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,11 @@
{
"text": "set print elements 0"
}
]
],
"symbolLoadInfo": {
"loadAll": false,
"exceptionList": "libcesium.omniverse.plugin.so;libcesium.omniverse.cpp.tests.plugin.so"
}
},
{
"name": "Python Debugging (attach)",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ PYBIND11_MODULE(CesiumOmniverseCppTestsPythonBindings, m) {
// clang-format off
carb::defineInterfaceClass<ICesiumOmniverseCppTestsInterface>(
m, "ICesiumOmniverseCppTestsInterface", "acquire_cesium_omniverse_tests_interface", "release_cesium_omniverse_tests_interface")
.def("run_all_tests", &ICesiumOmniverseCppTestsInterface::run_all_tests)
.def("run_all_tests", &ICesiumOmniverseCppTestsInterface::runAllTests)
.def("on_startup", &ICesiumOmniverseCppTestsInterface::onStartup)
.def("on_shutdown", &ICesiumOmniverseCppTestsInterface::onShutdown);
// clang-format on
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class ICesiumOmniverseCppTestsInterface {
*/
virtual void onShutdown() noexcept = 0;

virtual void run_all_tests(long int stage_id) noexcept = 0;
virtual void runAllTests(long int stage_id) noexcept = 0;
};

} // namespace cesium::omniverse::tests
2 changes: 1 addition & 1 deletion cesiumOmniverseCppTestsExtension/include/UsdUtilTests.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
#pragma once

void run_all_UsdUtil_tests();
void runAllUsdUtilTests();
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ class CesiumOmniverseCppTestsPlugin final : public ICesiumOmniverseCppTestsInter
Context::onShutdown();
}

void run_all_tests(long int stage_id) noexcept override {
void runAllTests(long int stage_id) noexcept override {

CESIUM_LOG_INFO("Running Cesium Omniverse Tests with stage id: {}", stage_id);

Expand All @@ -80,7 +80,7 @@ class CesiumOmniverseCppTestsPlugin final : public ICesiumOmniverseCppTestsInter
context.setAssertHandler(handler);

exampleTest();
run_all_UsdUtil_tests();
runAllUsdUtilTests();

CESIUM_LOG_INFO("Cesium Omniverse Tests complete");
}
Expand Down
11 changes: 3 additions & 8 deletions cesiumOmniverseCppTestsExtension/public/UsdUtilTests.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
// #define DOCTEST_CONFIG_IMPLEMENT
// #define DOCTEST_CONFIG_IMPLEMENTATION_IN_DLL
// #define DOCTEST_CONFIG_SUPER_FAST_ASSERTS

#include "UsdUtilTests.h"

#include "cesium/omniverse/Context.h"
Expand All @@ -10,11 +6,10 @@

#include <doctest/doctest.h>

#include <iostream>

void run_all_UsdUtil_tests() {
void runAllUsdUtilTests() {
// CESIUM_LOG_INFO macro can only be run inside the cesium::omniverse namespace
using namespace cesium::omniverse;
CESIUM_LOG_INFO("Running UsdUtil Tests...");
CHECK(cesium::omniverse::UsdUtil::primExists(pxr::SdfPath("/Cesium")));
CHECK(UsdUtil::primExists(pxr::SdfPath("/Cesium")));
CESIUM_LOG_INFO("UsdUtil Tests complete!");
}

0 comments on commit d4520ff

Please sign in to comment.