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 "remoting/test/refresh_token_store.h" | 5 #include "remoting/test/refresh_token_store.h" |
6 | 6 |
7 #include "base/files/file_util.h" | 7 #include "base/files/file_util.h" |
8 #include "base/files/important_file_writer.h" | 8 #include "base/files/important_file_writer.h" |
9 #include "base/json/json_reader.h" | 9 #include "base/json/json_reader.h" |
10 #include "base/json/json_writer.h" | 10 #include "base/json/json_writer.h" |
11 #include "base/logging.h" | 11 #include "base/logging.h" |
| 12 #include "base/macros.h" |
12 #include "base/values.h" | 13 #include "base/values.h" |
13 | 14 |
14 namespace { | 15 namespace { |
15 const base::FilePath::CharType kTokenFileName[] = | 16 const base::FilePath::CharType kTokenFileName[] = |
16 FILE_PATH_LITERAL("refresh_tokens.json"); | 17 FILE_PATH_LITERAL("refresh_tokens.json"); |
17 const base::FilePath::CharType kRemotingFolder[] = | 18 const base::FilePath::CharType kRemotingFolder[] = |
18 FILE_PATH_LITERAL("remoting"); | 19 FILE_PATH_LITERAL("remoting"); |
19 const base::FilePath::CharType kRefreshTokenStoreFolder[] = | 20 const base::FilePath::CharType kRefreshTokenStoreFolder[] = |
20 FILE_PATH_LITERAL("token_store"); | 21 FILE_PATH_LITERAL("token_store"); |
21 } // namespace | 22 } // namespace |
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
159 | 160 |
160 scoped_ptr<RefreshTokenStore> RefreshTokenStore::OnDisk( | 161 scoped_ptr<RefreshTokenStore> RefreshTokenStore::OnDisk( |
161 const std::string& user_name, | 162 const std::string& user_name, |
162 const base::FilePath& refresh_token_file_path) { | 163 const base::FilePath& refresh_token_file_path) { |
163 return make_scoped_ptr<RefreshTokenStore>( | 164 return make_scoped_ptr<RefreshTokenStore>( |
164 new RefreshTokenStoreOnDisk(user_name, refresh_token_file_path)); | 165 new RefreshTokenStoreOnDisk(user_name, refresh_token_file_path)); |
165 } | 166 } |
166 | 167 |
167 } // namespace test | 168 } // namespace test |
168 } // namespace remoting | 169 } // namespace remoting |
OLD | NEW |