mirror of
https://github.com/thunderbrewhq/common.git
synced 2025-12-12 03:02:29 +00:00
16 lines
368 B
C++
16 lines
368 B
C++
|
|
#include "common/Handle.hpp"
|
||
|
|
#include "test/Test.hpp"
|
||
|
|
|
||
|
|
class TestHandleObject : public CHandleObject {};
|
||
|
|
|
||
|
|
TEST_CASE("HandleCreate", "[handle]") {
|
||
|
|
SECTION("returns handle for subclass of CHandleObject") {
|
||
|
|
auto testObject = new TestHandleObject();
|
||
|
|
|
||
|
|
auto handle = HandleCreate(testObject);
|
||
|
|
CHECK(handle);
|
||
|
|
|
||
|
|
HandleClose(handle);
|
||
|
|
}
|
||
|
|
}
|