mirror of
https://github.com/slint-ui/slint.git
synced 2025-08-04 18:58:36 +00:00
parent
a0dd643d83
commit
83ccd07a88
3 changed files with 22 additions and 0 deletions
|
@ -28,3 +28,19 @@ TEST_CASE("Basic Window Visibility")
|
|||
instance->hide();
|
||||
REQUIRE(instance->window().is_visible() == false);
|
||||
}
|
||||
|
||||
TEST_CASE("Window Scale Factory Existence")
|
||||
{
|
||||
using namespace slint::interpreter;
|
||||
using namespace slint;
|
||||
|
||||
ComponentCompiler compiler;
|
||||
auto comp_def = compiler.build_from_source(R"(
|
||||
export App := Window {
|
||||
}
|
||||
)",
|
||||
"");
|
||||
REQUIRE(comp_def.has_value());
|
||||
auto instance = comp_def->create();
|
||||
REQUIRE(instance->window().scale_factor() > 0);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue