Write C++ wrapper round the current implementation of ut-core
Wrap UT_ASSERT_XXX to GTEST_ASSERT_XXX
Bring up /test suite up to support UT_CORE C++ environment built though ut-core
Write a test using UT_CORE C++ to prove functionality is working
G TEST / UT_CORE Test should be swappable to allow 100% compatibility
Subdivide the tests - test/c & test/c++ or something to support different frameworks
Key Deliverables
[ ] Wrapper for UT_CORE is present
[ ] Write a simple test to prove functionality is working
[ ]
[ ]
Jira:-
This Jira issue details the user story that directly aligns with this milestone's goals and deliverables.
Include the Jira ID for easy reference and tracking.
Additional Notes (Optional)
This gtest test should work 100% through the ut-core C++ framework as an example
#include "gtest/gtest.h" // Include the gtest header
// Function to be tested
int add(int a, int b) {
return a + b;
}
// Test case for the add function
TEST(MathTest, AddTest) {
EXPECT_EQ(add(2, 3), 5); // Test if 2 + 3 = 5
EXPECT_EQ(add(-1, 1), 0); // Test if -1 + 1 = 0
EXPECT_NE(add(10, 5), 14); // Test if 10 + 5 is NOT equal to 14
}
int main(int argc, char **argv) {
testing::InitGoogleTest(&argc, argv);
return RUN_ALL_TESTS(); // Execute all defined tests
}
But to enable extended features, we would support this upgrade to the test
#include "ut-core-cpp.h" // Include the framework header
// Function to be tested
int add(int a, int b) {
return a + b;
}
// Test case for the add function
TEST(MathTest, AddTest) {
EXPECT_EQ(add(2, 3), 5); // Test if 2 + 3 = 5
EXPECT_EQ(add(-1, 1), 0); // Test if -1 + 1 = 0
EXPECT_NE(add(10, 5), 14); // Test if 10 + 5 is NOT equal to 14
}
int main(int argc, char **argv) {
ut-core::Init(&argc, argv);
return RUN_ALL_TESTS(); // Execute all defined tests
}
Goals
Key Deliverables
[ ] Wrapper for UT_CORE is present
[ ] Write a simple test to prove functionality is working
[ ]
[ ]
Jira:-
Additional Notes (Optional)
This gtest test should work 100% through the ut-core C++ framework as an example
But to enable extended features, we would support this upgrade to the test