add unit test for putchar on tab #1233

pull/2623/head
nick black 2 years ago committed by nick black
parent 28756a004f
commit 6bf37089a1

@ -0,0 +1,22 @@
#include <cstdlib>
#include "main.h"
TEST_CASE("TaBs") { // refreshing and delicious
auto nc_ = testing_notcurses();
if(!nc_){
return;
}
struct ncplane* n_ = notcurses_stdplane(nc_);
REQUIRE(n_);
SUBCASE("PutcTaB") {
unsigned y, x;
CHECK(1 == ncplane_putchar(n_, '\n'));
ncplane_cursor_yx(n_, &y, &x);
CHECK(y == 8);
CHECK(x == 0);
}
CHECK(0 == notcurses_stop(nc_));
}
Loading…
Cancel
Save