| 68 | } |
| 69 | |
| 70 | TEST(GeometryStore, AllocateAndDeallocate) |
| 71 | { |
| 72 | render::GeometryStore store(TestSyncObjectProvider::Instance(), _testBufferObjectProvider); |
| 73 | |
| 74 | std::vector<render::IGeometryStore::Slot> allocatedSlots; |
| 75 | |
| 76 | // Allocate 10 slots of various sizes |
| 77 | for (auto i = 0; i < 10; ++i) |
| 78 | { |
| 79 | auto slot = store.allocateSlot((i + 5) * 20, (i + 5) * 23); |
| 80 | EXPECT_NE(slot, std::numeric_limits<render::IGeometryStore::Slot>::max()) << "Invalid slot"; |
| 81 | |
| 82 | allocatedSlots.push_back(slot); |
| 83 | } |
| 84 | |
| 85 | for (auto slot : allocatedSlots) |
| 86 | { |
| 87 | EXPECT_NO_THROW(store.deallocateSlot(slot)); |
| 88 | } |
| 89 | } |
| 90 | |
| 91 | TEST(GeometryStore, UpdateData) |
| 92 | { |
nothing calls this directly
no test coverage detected