| 60 | } |
| 61 | |
| 62 | TEST(CEnvAPI, TVMFFIEnvSetDLPackManagedTensorAllocator) { |
| 63 | auto old_allocator = TVMFFIEnvGetDLPackManagedTensorAllocator(); |
| 64 | DLPackManagedTensorAllocator pre_allocator; |
| 65 | TVMFFIEnvSetDLPackManagedTensorAllocator(TestDLPackManagedTensorAllocator, 0, &pre_allocator); |
| 66 | EXPECT_EQ(old_allocator, pre_allocator); |
| 67 | TVMFFIEnvSetDLPackManagedTensorAllocator(old_allocator, 0, nullptr); |
| 68 | } |
| 69 | |
| 70 | TEST(CEnvAPI, TVMFFIEnvTensorAlloc) { |
| 71 | auto old_allocator = TVMFFIEnvGetDLPackManagedTensorAllocator(); |
nothing calls this directly
no test coverage detected