minor changes to tests
This commit is contained in:
@@ -1,3 +1,7 @@
|
||||
# ISSUES
|
||||
No matter what I do it says that there are 2666 allocations or something. This
|
||||
is concerning.
|
||||
|
||||
# A collection of libraries inspired by zig
|
||||
|
||||
I like zig, but I really like writing C. I am starting with implementing
|
||||
|
||||
@@ -13,14 +13,15 @@ Test(borrow_allocator, test) {
|
||||
borrow_allocator_assert_all_freed(&balloc);
|
||||
}
|
||||
|
||||
|
||||
// TODO: when I update the number of allocations it does not seem to change the
|
||||
// number of allocated bytes...
|
||||
#define IS_SIZE 900
|
||||
Test(borrow_allocator, with) {
|
||||
with_borrow(foo) {
|
||||
allocator_alloc(foo, 1000);
|
||||
allocator_alloc(foo, 100);
|
||||
allocator_alloc(foo, 90);
|
||||
int *is = allocator_alloc(foo, sizeof(int) * IS_SIZE);
|
||||
for (int i = 0; i < IS_SIZE; i++) is[i] = i;
|
||||
is = allocator_alloc(foo, sizeof(int) * IS_SIZE);
|
||||
for (int i = 0; i < IS_SIZE; i++) is[i] = i;
|
||||
is = allocator_alloc(foo, sizeof(int) * IS_SIZE);
|
||||
for (int i = 0; i < IS_SIZE; i++) is[i] = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user