Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(106)

Side by Side Diff: chrome/browser/webdata/token_service_table_unittest.cc

Issue 13392014: Move c/b/webdata/ code to components/webdata/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Pure merge Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "base/file_util.h" 5 #include "base/file_util.h"
6 #include "base/files/scoped_temp_dir.h" 6 #include "base/files/scoped_temp_dir.h"
7 #include "base/path_service.h" 7 #include "base/path_service.h"
8 #include "base/strings/string_number_conversions.h" 8 #include "base/strings/string_number_conversions.h"
9 #include "base/time.h" 9 #include "base/time.h"
10 #include "chrome/browser/webdata/token_service_table.h" 10 #include "chrome/browser/webdata/token_service_table.h"
11 #include "chrome/browser/webdata/web_database.h" 11 #include "components/webdata/common/web_database.h"
12 #include "testing/gtest/include/gtest/gtest.h" 12 #include "testing/gtest/include/gtest/gtest.h"
13 13
14 using base::Time; 14 using base::Time;
15 15
16 class TokenServiceTableTest : public testing::Test { 16 class TokenServiceTableTest : public testing::Test {
17 public: 17 public:
18 TokenServiceTableTest() {} 18 TokenServiceTableTest() {}
19 virtual ~TokenServiceTableTest() {} 19 virtual ~TokenServiceTableTest() {}
20 20
21 protected: 21 protected:
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 EXPECT_TRUE(table_->SetTokenForService(service, "")); 83 EXPECT_TRUE(table_->SetTokenForService(service, ""));
84 EXPECT_TRUE(table_->GetAllTokens(&out_map)); 84 EXPECT_TRUE(table_->GetAllTokens(&out_map));
85 EXPECT_EQ(out_map.find(service)->second, ""); 85 EXPECT_EQ(out_map.find(service)->second, "");
86 out_map.clear(); 86 out_map.clear();
87 87
88 // try mutating it 88 // try mutating it
89 EXPECT_TRUE(table_->SetTokenForService(service, "ham")); 89 EXPECT_TRUE(table_->SetTokenForService(service, "ham"));
90 EXPECT_TRUE(table_->GetAllTokens(&out_map)); 90 EXPECT_TRUE(table_->GetAllTokens(&out_map));
91 EXPECT_EQ(out_map.find(service)->second, "ham"); 91 EXPECT_EQ(out_map.find(service)->second, "ham");
92 } 92 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698