mirror of
https://gitlab.com/dosowisko.net/libsuperderpy.git
synced 2024-12-05 00:38:00 +01:00
tests: Fix memory leaks in Character tests
This commit is contained in:
parent
67b6a763c3
commit
1d569e9913
1 changed files with 4 additions and 0 deletions
|
@ -76,6 +76,8 @@ static void character_spritesheet_stops(void** state) {
|
|||
assert_int_equal(character->pos, 2);
|
||||
AnimateCharacter(game, character, 0.1, 1.0);
|
||||
assert_int_equal(character->pos, 2);
|
||||
|
||||
DestroyCharacter(game, character);
|
||||
}
|
||||
|
||||
static void character_spritesheet_reversed_stops(void** state) {
|
||||
|
@ -93,6 +95,8 @@ static void character_spritesheet_reversed_stops(void** state) {
|
|||
assert_int_equal(character->pos, 0);
|
||||
AnimateCharacter(game, character, 0.1, 1.0);
|
||||
assert_int_equal(character->pos, 0);
|
||||
|
||||
DestroyCharacter(game, character);
|
||||
}
|
||||
|
||||
int test_character(void) {
|
||||
|
|
Loading…
Reference in a new issue