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

Side by Side Diff: mojo/dart/unittests/embedder_tester/validation_unittest.cc

Issue 1641513004: Update //base to chromium 9659b08ea5a34f889dc4166217f438095ddc10d2 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 4 years, 10 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
OLDNEW
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 <set> 5 #include <set>
6 #include <string> 6 #include <string>
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/files/file_enumerator.h" 10 #include "base/files/file_enumerator.h"
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 } 72 }
73 file_path = file_path.RemoveExtension(); 73 file_path = file_path.RemoveExtension();
74 tests.insert(file_path.value()); 74 tests.insert(file_path.value());
75 } 75 }
76 std::vector<std::string> result; 76 std::vector<std::string> result;
77 for (auto it = tests.begin(); it != tests.end(); it++) { 77 for (auto it = tests.begin(); it != tests.end(); it++) {
78 const std::string& test_name = *it; 78 const std::string& test_name = *it;
79 std::string source; 79 std::string source;
80 bool r; 80 bool r;
81 std::string filename = base::FilePath(test_name).BaseName().value(); 81 std::string filename = base::FilePath(test_name).BaseName().value();
82 if (!StartsWithASCII(filename, "conformance_", true)) { 82 if (!base::StartsWith(filename, "conformance_",
83 base::CompareCase::SENSITIVE)) {
83 // Only include conformance tests. 84 // Only include conformance tests.
84 continue; 85 continue;
85 } 86 }
86 base::FilePath data_path(test_name); 87 base::FilePath data_path(test_name);
87 data_path = data_path.AddExtension(".data"); 88 data_path = data_path.AddExtension(".data");
88 base::FilePath expected_path(test_name); 89 base::FilePath expected_path(test_name);
89 expected_path = expected_path.AddExtension(".expected"); 90 expected_path = expected_path.AddExtension(".expected");
90 // Test name. 91 // Test name.
91 result.push_back(test_name.c_str()); 92 result.push_back(test_name.c_str());
92 // Test's .data. 93 // Test's .data.
(...skipping 11 matching lines...) Expand all
104 } 105 }
105 }; 106 };
106 107
107 TEST_F(DartValidationTest, validation) { 108 TEST_F(DartValidationTest, validation) {
108 RunTest(GetPath()); 109 RunTest(GetPath());
109 } 110 }
110 111
111 } // namespace 112 } // namespace
112 } // namespace dart 113 } // namespace dart
113 } // namespace mojo 114 } // namespace mojo
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698