OLD | NEW |
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 <vector> | 5 #include <vector> |
6 | 6 |
7 #include "base/files/file_path.h" | 7 #include "base/files/file_path.h" |
8 #include "base/path_service.h" | 8 #include "base/path_service.h" |
9 #include "base/strings/string_util.h" | 9 #include "base/strings/string_util.h" |
10 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
42 // file that contains one or more forms. The corresponding output file lists the | 42 // file that contains one or more forms. The corresponding output file lists the |
43 // heuristically detected type for eachfield. | 43 // heuristically detected type for eachfield. |
44 class FormStructureBrowserTest : public InProcessBrowserTest, | 44 class FormStructureBrowserTest : public InProcessBrowserTest, |
45 public DataDrivenTest { | 45 public DataDrivenTest { |
46 protected: | 46 protected: |
47 FormStructureBrowserTest(); | 47 FormStructureBrowserTest(); |
48 virtual ~FormStructureBrowserTest(); | 48 virtual ~FormStructureBrowserTest(); |
49 | 49 |
50 // DataDrivenTest: | 50 // DataDrivenTest: |
51 virtual void GenerateResults(const std::string& input, | 51 virtual void GenerateResults(const std::string& input, |
52 std::string* output) OVERRIDE; | 52 std::string* output) override; |
53 | 53 |
54 // Serializes the given |forms| into a string. | 54 // Serializes the given |forms| into a string. |
55 std::string FormStructuresToString(const std::vector<FormStructure*>& forms); | 55 std::string FormStructuresToString(const std::vector<FormStructure*>& forms); |
56 | 56 |
57 private: | 57 private: |
58 DISALLOW_COPY_AND_ASSIGN(FormStructureBrowserTest); | 58 DISALLOW_COPY_AND_ASSIGN(FormStructureBrowserTest); |
59 }; | 59 }; |
60 | 60 |
61 FormStructureBrowserTest::FormStructureBrowserTest() | 61 FormStructureBrowserTest::FormStructureBrowserTest() |
62 : DataDrivenTest(GetTestDataDir()) { | 62 : DataDrivenTest(GetTestDataDir()) { |
(...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
271 IN_PROC_BROWSER_TEST_F(FormStructureBrowserTest, | 271 IN_PROC_BROWSER_TEST_F(FormStructureBrowserTest, |
272 MAYBE_DataDrivenHeuristics(20)) { | 272 MAYBE_DataDrivenHeuristics(20)) { |
273 const base::FilePath::CharType kFileNamePattern[] = | 273 const base::FilePath::CharType kFileNamePattern[] = |
274 FILE_PATH_LITERAL("20_*.html"); | 274 FILE_PATH_LITERAL("20_*.html"); |
275 RunDataDrivenTest(GetInputDirectory(kTestName), | 275 RunDataDrivenTest(GetInputDirectory(kTestName), |
276 GetOutputDirectory(kTestName), | 276 GetOutputDirectory(kTestName), |
277 kFileNamePattern); | 277 kFileNamePattern); |
278 } | 278 } |
279 | 279 |
280 } // namespace autofill | 280 } // namespace autofill |
OLD | NEW |