Added catch2

This commit is contained in:
Antoine Pilote
2025-05-02 16:50:34 -04:00
parent 4aa33b6a20
commit 70141a7ee6
9 changed files with 26148 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
#include "catch2/catch_amalgamated.hpp"
#define CATCH_CONFIG_MAIN
#include "Engine.h"
namespace Engine
{
TEST_CASE("Window creation", "[window]")
{
Nuake::Engine::Init();
REQUIRE(Nuake::Engine::GetCurrentWindow() != nullptr);
}
TEST_CASE("Window shutdown", "[window]")
{
Nuake::Engine::Init();
Nuake::Engine::GetCurrentWindow()->Close();
REQUIRE(Nuake::Engine::GetCurrentWindow()->ShouldClose());
}
}