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

Side by Side Diff: chrome/common/json_value_serializer_unittest.cc

Issue 7048007: Move scoped_temp_dir and scoped_native_library back from base/memory to base. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: unknwn Created 9 years, 7 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/basictypes.h" 5 #include "base/basictypes.h"
6 #include "base/file_util.h" 6 #include "base/file_util.h"
7 #include "base/json/json_reader.h" 7 #include "base/json/json_reader.h"
8 #include "base/json/json_writer.h" 8 #include "base/json/json_writer.h"
9 #include "base/memory/scoped_temp_dir.h"
10 #include "base/path_service.h" 9 #include "base/path_service.h"
10 #include "base/scoped_temp_dir.h"
11 #include "base/string16.h" 11 #include "base/string16.h"
12 #include "base/string_util.h" 12 #include "base/string_util.h"
13 #include "base/utf_string_conversions.h" 13 #include "base/utf_string_conversions.h"
14 #include "base/values.h" 14 #include "base/values.h"
15 #include "chrome/common/chrome_paths.h" 15 #include "chrome/common/chrome_paths.h"
16 #include "content/common/json_value_serializer.h" 16 #include "content/common/json_value_serializer.h"
17 #include "testing/gtest/include/gtest/gtest.h" 17 #include "testing/gtest/include/gtest/gtest.h"
18 18
19 TEST(JSONValueSerializerTest, Roundtrip) { 19 TEST(JSONValueSerializerTest, Roundtrip) {
20 const std::string original_serialization = 20 const std::string original_serialization =
(...skipping 308 matching lines...) Expand 10 before | Expand all | Expand 10 after
329 FilePath source_file_path; 329 FilePath source_file_path;
330 ASSERT_TRUE(PathService::Get(chrome::DIR_TEST_DATA, &source_file_path)); 330 ASSERT_TRUE(PathService::Get(chrome::DIR_TEST_DATA, &source_file_path));
331 source_file_path = source_file_path.Append( 331 source_file_path = source_file_path.Append(
332 FILE_PATH_LITERAL("serializer_test_nowhitespace.js")); 332 FILE_PATH_LITERAL("serializer_test_nowhitespace.js"));
333 ASSERT_TRUE(file_util::PathExists(source_file_path)); 333 ASSERT_TRUE(file_util::PathExists(source_file_path));
334 JSONFileValueSerializer serializer(source_file_path); 334 JSONFileValueSerializer serializer(source_file_path);
335 scoped_ptr<Value> root; 335 scoped_ptr<Value> root;
336 root.reset(serializer.Deserialize(NULL, NULL)); 336 root.reset(serializer.Deserialize(NULL, NULL));
337 ASSERT_TRUE(root.get()); 337 ASSERT_TRUE(root.get());
338 } 338 }
OLDNEW
« no previous file with comments | « chrome/common/json_pref_store_unittest.cc ('k') | chrome/common/service_process_util_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698