utilitiec/tests/Scratchpad.test.c

25 lines
391 B
C
Raw Normal View History

2024-06-13 15:28:21 +02:00
#include "../src/Scratchpad/Scratchpad.h"
#include <assert.h>
#include <stdlib.h>
void test_reserve(void)
{
Scratchpad pad;
assert(Scratchpad_Create(&pad, 16, NULL) == EXIT_SUCCESS);
assert(Scratchpad_Reserve(&pad, 16) != NULL);
assert(Scratchpad_Reserve(&pad, 16) != NULL);
Scratchpad_Reset(&pad);
Scratchpad_Destroy(&pad);
return;
}
int main()
{
test_reserve();
return 0;
}