Home | History | Annotate | Download | only in threading

Lines Matching refs:Watchdog

5 #include "base/threading/watchdog.h"
20 class WatchdogCounter : public Watchdog {
25 : Watchdog(duration, thread_watched_name, enabled),
33 Watchdog::Alarm();
47 Watchdog::ResetStaticData();
58 Watchdog watchdog1(TimeDelta::FromMilliseconds(300), "Disabled", false);
59 Watchdog watchdog2(TimeDelta::FromMilliseconds(300), "Enabled", true);
64 Watchdog watchdog1(TimeDelta::FromMilliseconds(300), "Disabled", false);
70 Watchdog watchdog2(TimeDelta::FromMilliseconds(300), "Enabled", true);
79 WatchdogCounter watchdog(TimeDelta::FromMilliseconds(10), "Enabled", true);
80 watchdog.Arm();
82 watchdog.alarm_counter() > 0);
83 EXPECT_EQ(1, watchdog.alarm_counter());
88 WatchdogCounter watchdog(TimeDelta(), "Enabled2", true);
90 watchdog.ArmSomeTimeDeltaAgo(TimeDelta::FromSeconds(2));
93 watchdog.alarm_counter() > 0);
95 EXPECT_EQ(1, watchdog.alarm_counter());
100 WatchdogCounter watchdog(TimeDelta::FromMilliseconds(10), "Disabled", false);
101 watchdog.Arm();
104 EXPECT_EQ(0, watchdog.alarm_counter());
109 WatchdogCounter watchdog(TimeDelta::FromSeconds(1), "Enabled3", true);
112 watchdog.Arm();
115 watchdog.Disarm();
125 EXPECT_EQ(0, watchdog.alarm_counter());
130 EXPECT_EQ(0, watchdog.alarm_counter());
134 watchdog.ArmSomeTimeDeltaAgo(TimeDelta::FromSeconds(10));
137 watchdog.alarm_counter() > 0);
139 EXPECT_EQ(1, watchdog.alarm_counter());