OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "content/renderer/origin_trials/trial_token.h" | 5 #include "content/common/origin_trials/trial_token.h" |
6 | 6 |
7 #include "base/macros.h" | 7 #include "base/macros.h" |
8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
9 #include "base/strings/string_piece.h" | 9 #include "base/strings/string_piece.h" |
10 #include "base/strings/string_util.h" | 10 #include "base/strings/string_util.h" |
11 #include "base/test/simple_test_clock.h" | 11 #include "base/test/simple_test_clock.h" |
12 #include "base/time/time.h" | 12 #include "base/time/time.h" |
13 #include "testing/gtest/include/gtest/gtest.h" | 13 #include "testing/gtest/include/gtest/gtest.h" |
14 #include "url/gurl.h" | 14 #include "url/gurl.h" |
15 | 15 |
(...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
234 EXPECT_FALSE(token->IsValid(base::Time::FromDoubleT(kValidTimestamp), | 234 EXPECT_FALSE(token->IsValid(base::Time::FromDoubleT(kValidTimestamp), |
235 incorrect_public_key())); | 235 incorrect_public_key())); |
236 } | 236 } |
237 | 237 |
238 TEST_F(TrialTokenTest, ValidateWhenNotExpired) { | 238 TEST_F(TrialTokenTest, ValidateWhenNotExpired) { |
239 scoped_ptr<TrialToken> token = TrialToken::Parse(kSampleToken); | 239 scoped_ptr<TrialToken> token = TrialToken::Parse(kSampleToken); |
240 ASSERT_TRUE(token); | 240 ASSERT_TRUE(token); |
241 } | 241 } |
242 | 242 |
243 } // namespace content | 243 } // namespace content |
OLD | NEW |