Lines Matching refs:PrettyDuration
23 TEST(TimeUtilsTest, PrettyDuration) { in TEST() argument
28 EXPECT_EQ("1s", PrettyDuration(1 * one_sec)); in TEST()
29 EXPECT_EQ("10s", PrettyDuration(10 * one_sec)); in TEST()
30 EXPECT_EQ("100s", PrettyDuration(100 * one_sec)); in TEST()
31 EXPECT_EQ("1.001s", PrettyDuration(1 * one_sec + one_ms)); in TEST()
32 EXPECT_EQ("1.000001s", PrettyDuration(1 * one_sec + one_us, 6)); in TEST()
33 EXPECT_EQ("1.000000001s", PrettyDuration(1 * one_sec + 1, 9)); in TEST()
34 EXPECT_EQ("1.000s", PrettyDuration(1 * one_sec + one_us, 3)); in TEST()
36 EXPECT_EQ("1ms", PrettyDuration(1 * one_ms)); in TEST()
37 EXPECT_EQ("10ms", PrettyDuration(10 * one_ms)); in TEST()
38 EXPECT_EQ("100ms", PrettyDuration(100 * one_ms)); in TEST()
39 EXPECT_EQ("1.001ms", PrettyDuration(1 * one_ms + one_us)); in TEST()
40 EXPECT_EQ("1.000001ms", PrettyDuration(1 * one_ms + 1, 6)); in TEST()
42 EXPECT_EQ("1us", PrettyDuration(1 * one_us)); in TEST()
43 EXPECT_EQ("10us", PrettyDuration(10 * one_us)); in TEST()
44 EXPECT_EQ("100us", PrettyDuration(100 * one_us)); in TEST()
45 EXPECT_EQ("1.001us", PrettyDuration(1 * one_us + 1)); in TEST()
47 EXPECT_EQ("1ns", PrettyDuration(1)); in TEST()
48 EXPECT_EQ("10ns", PrettyDuration(10)); in TEST()
49 EXPECT_EQ("100ns", PrettyDuration(100)); in TEST()