#pragma once #include #include #include #include #include #include #include #include #include namespace test { inline void check(bool condition, const char* message) { if (!condition) { std::cerr << "FAILED: " << message << '\n'; std::exit(EXIT_FAILURE); } } inline bool close(float a, float b) { return std::abs(a - b) < 0.001f; } inline std::string readFile(const std::filesystem::path& path) { std::ifstream file(path, std::ios::binary); return {std::istreambuf_iterator(file), std::istreambuf_iterator()}; } inline GameObject* findByName(const Scene& scene, const std::string& name) { for (const auto& object : scene.GetObjects()) { if (object->GetName() == name) { return object.get(); } } return nullptr; } }