Skip to content

Commit

Permalink
tests/gpu_tests: use MEMEQ for pl_planar_tests
Browse files Browse the repository at this point in the history
Mostly just to dump the array on failure.
  • Loading branch information
haasn committed Feb 14, 2023
1 parent 11a0932 commit f2c4da9
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/tests/gpu_tests.h
Original file line number Diff line number Diff line change
Expand Up @@ -299,8 +299,9 @@ static void pl_planar_tests(pl_gpu gpu)
.ptr = data,
)));

for (int i = 0; i < PL_ARRAY_SIZE(data); i++)
REQUIRE_CMP(data[i], ==, 0x80, PRIu8);
uint8_t ref[PL_ARRAY_SIZE(data)];
memset(ref, 0x80, sizeof(ref));
REQUIRE_MEMEQ(data, ref, PL_ARRAY_SIZE(data));

pl_tex_destroy(gpu, &tex);
}
Expand Down

0 comments on commit f2c4da9

Please sign in to comment.