mirror of
https://github.com/jemalloc/jemalloc.git
synced 2026-08-24 16:13:38 +03:00
Change assert_* to expect_* in tests
```
grep -Irl assert_ test/ | xargs sed -i \
's/witness_assert/witness_do_not_replace/g';
grep -Irl assert_ test/ | xargs sed -i \
's/malloc_mutex_assert_owner/malloc_mutex_do_not_replace_owner/g';
grep -Ir assert_ test/ | grep -o "[_a-zA-Z]*assert_[_a-zA-Z]*" | \
grep -v "^assert_"; # confirm no output
grep -Irl assert_ test/ | xargs sed -i 's/assert_/expect_/g';
grep -Irl witness_do_not_replace test/ | xargs sed -i \
's/witness_do_not_replace/witness_assert/g';
grep -Irl malloc_mutex_do_not_replace_owner test/ | xargs sed -i \
's/malloc_mutex_do_not_replace_owner/malloc_mutex_assert_owner/g';
```
This commit is contained in:
parent
162c2bcf31
commit
21dfa4300d
85 changed files with 1854 additions and 1854 deletions
|
|
@ -15,7 +15,7 @@ TEST_BEGIN(test_next_event_fast_roll_back) {
|
|||
ITERATE_OVER_ALL_EVENTS
|
||||
#undef E
|
||||
void *p = malloc(16U);
|
||||
assert_ptr_not_null(p, "malloc() failed");
|
||||
expect_ptr_not_null(p, "malloc() failed");
|
||||
free(p);
|
||||
}
|
||||
TEST_END
|
||||
|
|
@ -37,7 +37,7 @@ TEST_BEGIN(test_next_event_fast_resume) {
|
|||
ITERATE_OVER_ALL_EVENTS
|
||||
#undef E
|
||||
void *p = malloc(SC_LOOKUP_MAXCLASS);
|
||||
assert_ptr_not_null(p, "malloc() failed");
|
||||
expect_ptr_not_null(p, "malloc() failed");
|
||||
free(p);
|
||||
}
|
||||
TEST_END
|
||||
|
|
@ -50,7 +50,7 @@ TEST_BEGIN(test_event_rollback) {
|
|||
while (count-- != 0) {
|
||||
te_alloc_rollback(tsd, diff);
|
||||
uint64_t thread_allocated_after = thread_allocated_get(tsd);
|
||||
assert_u64_eq(thread_allocated - thread_allocated_after, diff,
|
||||
expect_u64_eq(thread_allocated - thread_allocated_after, diff,
|
||||
"thread event counters are not properly rolled back");
|
||||
thread_allocated = thread_allocated_after;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue