diff options
author | Vicent Marti <vicent@github.com> | 2014-07-01 13:26:02 +0200 |
---|---|---|
committer | Vicent Marti <vicent@github.com> | 2014-07-01 13:26:02 +0200 |
commit | 1453bd20897d074a3f65d86f0d2bbb72ed23d071 (patch) | |
tree | 666ed1f4a261a1323600810d1591461181a068f2 /tests | |
parent | dcdb8500e3bd719010a1a65fffc391eef23dd4b4 (diff) | |
parent | 5fa8cda981940eaef54b55abe4fcba09b4e18e12 (diff) | |
download | libgit2-1453bd20897d074a3f65d86f0d2bbb72ed23d071.tar.gz |
Merge pull request #2451 from libgit2/rb/round-up-pool-allocations
Round up pool alloc sizes for alignment
Diffstat (limited to 'tests')
-rw-r--r-- | tests/core/pool.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/core/pool.c b/tests/core/pool.c index 351d0c20f..a7ec8801b 100644 --- a/tests/core/pool.c +++ b/tests/core/pool.c @@ -38,19 +38,19 @@ void test_core_pool__1(void) cl_assert(git_pool_malloc(&p, i) != NULL); /* with fixed page size, allocation must end up with these values */ - cl_assert(git_pool__open_pages(&p) == 1); - cl_assert(git_pool__full_pages(&p) == 505); + cl_assert_equal_i(1, git_pool__open_pages(&p)); + cl_assert_equal_i(507, git_pool__full_pages(&p)); git_pool_clear(&p); - cl_git_pass(git_pool_init(&p, 1, 4100)); + cl_git_pass(git_pool_init(&p, 1, 4120)); for (i = 2010; i > 0; i--) cl_assert(git_pool_malloc(&p, i) != NULL); /* with fixed page size, allocation must end up with these values */ - cl_assert(git_pool__open_pages(&p) == 1); - cl_assert(git_pool__full_pages(&p) == 492); + cl_assert_equal_i(1, git_pool__open_pages(&p)); + cl_assert_equal_i(492, git_pool__full_pages(&p)); git_pool_clear(&p); } |