Disable RTTI everywhere and fix Linux compilation
Former-commit-id: c8c0f11725d2e5b6c6da6dc3ab11f0eda065094f [formerly c2977e388c70ba7ccdf52f9eb97d7fe71ed6f4cf] [formerly 73c0d0759a6c9cad05dff59bff486f99fde336b6 [formerly 96a6e52ba5c97fd3a107fed5d11738466bd53f7e]] Former-commit-id: c6a193ee5ccb07a40a74719937dbf224ad22081e [formerly 5f275dc02a44bd2ee54f6d926338ddfe388f565b] Former-commit-id: e35640a20ac2269f96b75998e56fcba2fdbf6f00
This commit is contained in:
@@ -6,15 +6,23 @@ namespace
|
||||
class TestSystem : public Ndk::System<TestSystem>
|
||||
{
|
||||
public:
|
||||
TestSystem()
|
||||
TestSystem(int value) :
|
||||
m_value(value)
|
||||
{
|
||||
}
|
||||
|
||||
int GetValue() const
|
||||
{
|
||||
return m_value;
|
||||
}
|
||||
|
||||
~TestSystem() = default;
|
||||
|
||||
static Ndk::SystemIndex systemIndex;
|
||||
|
||||
private:
|
||||
int m_value;
|
||||
|
||||
void OnUpdate(float elapsedTime) override
|
||||
{
|
||||
}
|
||||
@@ -27,7 +35,7 @@ SCENARIO("System", "[NDK][SYSTEM]")
|
||||
{
|
||||
GIVEN("Our TestSystem")
|
||||
{
|
||||
TestSystem testSystem;
|
||||
TestSystem testSystem(666);
|
||||
|
||||
WHEN("We clone it")
|
||||
{
|
||||
@@ -35,7 +43,7 @@ SCENARIO("System", "[NDK][SYSTEM]")
|
||||
|
||||
THEN("We should get a copy")
|
||||
{
|
||||
REQUIRE(dynamic_cast<TestSystem*>(clone.get()) != nullptr);
|
||||
REQUIRE(static_cast<TestSystem*>(clone.get())->GetValue() == 42);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user