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

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

Issue 12886024: Move JSON schema validator code into its own directory in chrome/common (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 9 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
« no previous file with comments | « chrome/common/web_apps.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "chrome/common/web_apps.h" 5 #include "chrome/common/web_apps.h"
6 6
7 #include "base/file_util.h" 7 #include "base/file_util.h"
8 #include "base/files/file_path.h" 8 #include "base/files/file_path.h"
9 #include "base/json/json_file_value_serializer.h" 9 #include "base/json/json_file_value_serializer.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
11 #include "base/path_service.h" 11 #include "base/path_service.h"
12 #include "base/utf_string_conversions.h" 12 #include "base/utf_string_conversions.h"
13 #include "base/values.h" 13 #include "base/values.h"
14 #include "chrome/common/chrome_paths.h" 14 #include "chrome/common/chrome_paths.h"
15 #include "chrome/common/json_schema_validator.h" 15 #include "chrome/common/json_schema/json_schema_validator.h"
16 #include "testing/gtest/include/gtest/gtest.h" 16 #include "testing/gtest/include/gtest/gtest.h"
17 17
18 namespace { 18 namespace {
19 19
20 DictionaryValue* LoadDefinitionFile(const std::string& name) { 20 DictionaryValue* LoadDefinitionFile(const std::string& name) {
21 base::FilePath path; 21 base::FilePath path;
22 if (!PathService::Get(chrome::DIR_TEST_DATA, &path)) { 22 if (!PathService::Get(chrome::DIR_TEST_DATA, &path)) {
23 ADD_FAILURE() << "Could not get test data dir."; 23 ADD_FAILURE() << "Could not get test data dir.";
24 return NULL; 24 return NULL;
25 } 25 }
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after
183 ASSERT_EQ(data[i].width1, sizes[0].width()); 183 ASSERT_EQ(data[i].width1, sizes[0].width());
184 ASSERT_EQ(data[i].height1, sizes[0].height()); 184 ASSERT_EQ(data[i].height1, sizes[0].height());
185 } 185 }
186 if (sizes.size() > 1) { 186 if (sizes.size() > 1) {
187 ASSERT_EQ(data[i].width2, sizes[1].width()); 187 ASSERT_EQ(data[i].width2, sizes[1].width());
188 ASSERT_EQ(data[i].height2, sizes[1].height()); 188 ASSERT_EQ(data[i].height2, sizes[1].height());
189 } 189 }
190 } 190 }
191 } 191 }
192 } 192 }
OLDNEW
« no previous file with comments | « chrome/common/web_apps.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698