ASSERT_EQ(0U, GetAndResetCertificatesLoadedEventsCount());
base::RunLoop().RunUntilIdle();
EXPECT_EQ(1U, GetAndResetCertificatesLoadedEventsCount());
// The certificate list should be updated now, as the message loop's been run.
ASSERT_EQ(0U, GetAndResetCertificatesLoadedEventsCount());
base::RunLoop().RunUntilIdle();
EXPECT_EQ(1U, GetAndResetCertificatesLoadedEventsCount());
// The certificate list should be updated now, as the message loop's been run.