blob: 7f5ecc482c8d0f3c0ac4da1fcfe8614e71617337 (
plain) (
blame)
| 1
2
3
4
5
6
7
8
9
10
11
12
 | #include <library/cpp/testing/unittest/registar.h>
#include "uptime.h"
Y_UNIT_TEST_SUITE(TestUptimeSuite) {
    Y_UNIT_TEST(TestUptime) {
        auto t1 = Uptime();
        Sleep(TDuration::MilliSeconds(50)); // typical uptime resolution is 10-16 ms
        auto t2 = Uptime();
        UNIT_ASSERT(t2 > t1);
    }
}
 |