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

Unified Diff: base/test/launcher/test_launcher.cc

Issue 862133002: Update from https://crrev.com/312398 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: base/test/launcher/test_launcher.cc
diff --git a/base/test/launcher/test_launcher.cc b/base/test/launcher/test_launcher.cc
index af2e461bc01d28361c103ec3a5b616801116810c..b5316ad8e8c998e2c830e45f01ae0e038e89d34f 100644
--- a/base/test/launcher/test_launcher.cc
+++ b/base/test/launcher/test_launcher.cc
@@ -829,6 +829,11 @@ bool TestLauncher::Init() {
}
}
+ if (!launcher_delegate_->GetTests(&tests_)) {
+ LOG(ERROR) << "Failed to get list of tests.";
+ return false;
+ }
+
if (!results_tracker_.Init(*command_line)) {
LOG(ERROR) << "Failed to initialize test results tracker.";
return 1;
@@ -900,12 +905,10 @@ bool TestLauncher::Init() {
}
void TestLauncher::RunTests() {
- std::vector<SplitTestName> tests(GetCompiledInTests());
-
std::vector<std::string> test_names;
-
- for (size_t i = 0; i < tests.size(); i++) {
- std::string test_name = FormatFullTestName(tests[i].first, tests[i].second);
+ for (size_t i = 0; i < tests_.size(); i++) {
+ std::string test_name = FormatFullTestName(
+ tests_[i].first, tests_[i].second);
results_tracker_.AddTest(test_name);
@@ -918,7 +921,7 @@ void TestLauncher::RunTests() {
continue;
}
- if (!launcher_delegate_->ShouldRunTest(tests[i].first, tests[i].second))
+ if (!launcher_delegate_->ShouldRunTest(tests_[i].first, tests_[i].second))
continue;
// Skip the test that doesn't match the filter (if given).

Powered by Google App Engine
This is Rietveld 408576698