From 6d771874a89eb4c6399b902c743c9a2333f803c3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20Men=C5=A1=C3=ADk?= Date: Sat, 11 Mar 2023 19:12:47 +0100 Subject: [PATCH] test: do not fail unit test because cpu speed 0 (#277) --- test/uvw/util.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/uvw/util.cpp b/test/uvw/util.cpp index 31f184e8..9a5ba91a 100644 --- a/test/uvw/util.cpp +++ b/test/uvw/util.cpp @@ -60,7 +60,8 @@ TEST(Util, Utilities) { ASSERT_NE(cpuInfo.size(), decltype(cpuInfo.size()){0}); ASSERT_FALSE(cpuInfo[0].model.empty()); - ASSERT_NE(cpuInfo[0].speed, decltype(cpuInfo[0].speed){0}); + /* returns 0 on unsupported architectures */ + ASSERT_GE(cpuInfo[0].speed, decltype(cpuInfo[0].speed){0}); auto interfaceAddresses = uvw::utilities::interface_addresses();