mirror of
https://github.com/dankamongmen/notcurses.git
synced 2024-11-06 03:20:26 +00:00
bulk up ResizeThenRotateFromFile test
This commit is contained in:
parent
cbc9a6ce6e
commit
1b32823e42
@ -25,8 +25,6 @@ TEST_CASE("Media") {
|
||||
SUBCASE("ResizeThenRotateFromFile") {
|
||||
auto ncv = ncvisual_from_file(find_data("changes.jpg").get());
|
||||
REQUIRE(nullptr != ncv);
|
||||
CHECK(0 == ncvisual_resize(ncv, 20, 20));
|
||||
CHECK(0 == ncvisual_rotate(ncv, M_PI / 2));
|
||||
struct ncvisual_options vopts{};
|
||||
vopts.x = NCALIGN_CENTER;
|
||||
vopts.y = NCALIGN_CENTER;
|
||||
@ -34,7 +32,24 @@ TEST_CASE("Media") {
|
||||
auto p = ncvisual_render(nc_, ncv, &vopts);
|
||||
REQUIRE(nullptr != p);
|
||||
CHECK(0 == notcurses_render(nc_));
|
||||
ncplane_destroy(p);
|
||||
sleep(1);
|
||||
CHECK(0 == ncplane_destroy(p));
|
||||
CHECK(0 == ncvisual_resize(ncv, 20, 20));
|
||||
p = ncvisual_render(nc_, ncv, &vopts);
|
||||
CHECK(0 == notcurses_render(nc_));
|
||||
sleep(1);
|
||||
CHECK(0 == ncplane_destroy(p));
|
||||
p = ncvisual_render(nc_, ncv, &vopts);
|
||||
REQUIRE(nullptr != p);
|
||||
CHECK(0 == notcurses_render(nc_));
|
||||
sleep(1);
|
||||
CHECK(0 == ncplane_destroy(p));
|
||||
CHECK(0 == ncvisual_rotate(ncv, M_PI / 2));
|
||||
p = ncvisual_render(nc_, ncv, &vopts);
|
||||
REQUIRE(nullptr != p);
|
||||
CHECK(0 == notcurses_render(nc_));
|
||||
sleep(1);
|
||||
CHECK(0 == ncplane_destroy(p));
|
||||
ncvisual_destroy(ncv);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user