test(platform): cover native integration failures
This commit is contained in:
@@ -4,6 +4,8 @@
|
||||
#include <izo/Dialogs.hpp>
|
||||
#include <izo/Environment.hpp>
|
||||
#include <izo/MessageBox.hpp>
|
||||
#include <izo/Notifications.hpp>
|
||||
#include <izo/System.hpp>
|
||||
|
||||
int main() {
|
||||
std::string error;
|
||||
@@ -45,4 +47,20 @@ int main() {
|
||||
error.clear();
|
||||
CHECK(!izo::GetClipboardText(&error));
|
||||
CHECK(!error.empty());
|
||||
error.clear();
|
||||
CHECK(!izo::SetClipboardFiles({}, &error));
|
||||
CHECK(!error.empty());
|
||||
error.clear();
|
||||
CHECK(!izo::GetClipboardFiles(&error));
|
||||
CHECK(!error.empty());
|
||||
error.clear();
|
||||
CHECK(!izo::SetClipboardImage({1, 1, {}}, &error));
|
||||
CHECK(!error.empty());
|
||||
error.clear();
|
||||
CHECK(!izo::ShowNotification("title", "message", &error));
|
||||
CHECK(!error.empty());
|
||||
error.clear();
|
||||
CHECK(!izo::PreventSleep(&error));
|
||||
CHECK(!error.empty());
|
||||
CHECK(izo::AllowSleep());
|
||||
}
|
||||
|
||||
@@ -11,6 +11,8 @@ int main() {
|
||||
CHECK(info.availableMemoryBytes <= info.totalMemoryBytes);
|
||||
CHECK(info.osName == "Linux");
|
||||
CHECK(!info.osVersion.empty());
|
||||
const auto battery = izo::GetBatteryInfo();
|
||||
CHECK(battery.levelPercent >= -1 && battery.levelPercent <= 100);
|
||||
|
||||
const auto before = izo::MonotonicNow();
|
||||
izo::SleepFor(std::chrono::milliseconds(5));
|
||||
|
||||
Reference in New Issue
Block a user