Fixes Flaky test by set larger timer(100 ->1000 ms) for CancelableAlarm.
PiperOrigin-RevId: 450911652
diff --git a/internal/platform/cancelable_alarm_test.cc b/internal/platform/cancelable_alarm_test.cc
index bde8524..8dfd297 100644
--- a/internal/platform/cancelable_alarm_test.cc
+++ b/internal/platform/cancelable_alarm_test.cc
@@ -70,9 +70,9 @@
AtomicReference<int> count(0);
CancelableAlarm alarm(
"test_alarm", [&count]() { count.Set(count.Get() + 1); },
- absl::Milliseconds(100), &alarm_executor, /*is_recurring=*/true);
- // Wait for 2 rounds (>100ms * 2) and expect the `count` = 2.
- SystemClock::Sleep(absl::Milliseconds(290));
+ absl::Milliseconds(1000), &alarm_executor, /*is_recurring=*/true);
+ // Wait for 2 rounds (>1000ms * 2) and expect the `count` = 2.
+ SystemClock::Sleep(absl::Milliseconds(2800));
alarm.Cancel();
EXPECT_EQ(count.Get(), 2);
}