Chromium Code Reviews| Index: chrome/browser/metrics/variations_service_unittest.cc |
| diff --git a/chrome/browser/metrics/variations_service_unittest.cc b/chrome/browser/metrics/variations_service_unittest.cc |
| index 084d2ab82b2a6957ccf5b35a2af1bce16be20539..d3fe4cfaba3a67dbf441758597e00f896cd7590f 100644 |
| --- a/chrome/browser/metrics/variations_service_unittest.cc |
| +++ b/chrome/browser/metrics/variations_service_unittest.cc |
| @@ -11,7 +11,7 @@ namespace { |
| // Converts |time| to chrome_variations::Study proto format. |
| int64 TimeToProtoTime(const base::Time& time) { |
| - return (time - base::Time::UnixEpoch()).InMilliseconds(); |
| + return (time - base::Time::UnixEpoch()).InSeconds(); |
| } |
| } // namespace |
| @@ -39,7 +39,7 @@ TEST(VariationsServiceTest, CheckStudyChannel) { |
| // instead of < so that the result of adding the last channel gets checked. |
| for (size_t i = 0; i <= arraysize(study_channels); ++i) { |
| for (size_t j = 0; j < arraysize(channels); ++j) { |
| - const bool expected = channel_added[j]; |
| + const bool expected = channel_added[j] || study.channel_size()==0; |
|
Alexei Svitkine (slow)
2012/05/08 03:40:13
Spaces around ==.
jwd
2012/05/08 03:47:24
Done.
|
| const bool result = VariationsService::CheckStudyChannel(study, |
| channels[j]); |
| EXPECT_EQ(expected, result) << "Case " << i << "," << j << " failed!"; |
| @@ -57,7 +57,7 @@ TEST(VariationsServiceTest, CheckStudyChannel) { |
| memset(&channel_added, 0, sizeof(channel_added)); |
| for (size_t i = 0; i <= arraysize(study_channels); ++i) { |
| for (size_t j = 0; j < arraysize(channels); ++j) { |
| - const bool expected = channel_added[j]; |
| + const bool expected = channel_added[j] || study.channel_size()==0; |
|
Alexei Svitkine (slow)
2012/05/08 03:40:13
Spaces around ==.
jwd
2012/05/08 03:47:24
Done.
|
| const bool result = VariationsService::CheckStudyChannel(study, |
| channels[j]); |
| EXPECT_EQ(expected, result) << "Case " << i << "," << j << " failed!"; |