diff --git a/tests/cell.cpp b/tests/cell.cpp index ac4d0e8b1..8c3843d6b 100644 --- a/tests/cell.cpp +++ b/tests/cell.cpp @@ -25,8 +25,7 @@ TEST_CASE("Cell") { if(getenv("TERM") == nullptr){ return; } - FILE* outfp_{}; - outfp_ = fopen("/dev/tty", "wb"); + FILE* outfp_ = fopen("/dev/tty", "wb"); REQUIRE(nullptr != outfp_); notcurses_options nopts{}; nopts.inhibit_alternate_screen = true; diff --git a/tests/direct.cpp b/tests/direct.cpp index 98450c9de..a4c4ee8c3 100644 --- a/tests/direct.cpp +++ b/tests/direct.cpp @@ -5,8 +5,7 @@ TEST_CASE("DirectMode") { if(getenv("TERM") == nullptr){ return; } - FILE* outfp_{}; - outfp_ = fopen("/dev/tty", "wb"); + FILE* outfp_ = fopen("/dev/tty", "wb"); REQUIRE(nullptr != outfp_); struct ncdirect* nc_ = ncdirect_init(NULL, outfp_); REQUIRE(nullptr != nc_); diff --git a/tests/metric.cpp b/tests/metric.cpp index b98005f22..2c8367274 100644 --- a/tests/metric.cpp +++ b/tests/metric.cpp @@ -20,6 +20,9 @@ char* impericize_ncmetric(uintmax_t val, unsigned decimal, char* buf, } TEST_CASE("ncmetric") { + if(!enforce_utf8()){ + return; + } const char* decisep = localeconv()->decimal_point; REQUIRE(decisep); REQUIRE(1 == strlen(decisep));