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

Side by Side Diff: components/dom_distiller/content/browser/test/dom_distiller_js_browsertest.cc

Issue 1532453002: Run all the tests in DomDistillerJsTest.RunJsTests (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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
« no previous file with comments | « no previous file | 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 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 "base/callback.h" 5 #include "base/callback.h"
6 #include "base/location.h" 6 #include "base/location.h"
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/path_service.h" 8 #include "base/path_service.h"
9 #include "base/run_loop.h" 9 #include "base/run_loop.h"
10 #include "base/single_thread_task_runner.h" 10 #include "base/single_thread_task_runner.h"
(...skipping 30 matching lines...) Expand all
41 private: 41 private:
42 base::Closure callback_; 42 base::Closure callback_;
43 }; 43 };
44 44
45 } // namespace 45 } // namespace
46 46
47 namespace dom_distiller { 47 namespace dom_distiller {
48 48
49 const char* kExternalTestResourcesPath = 49 const char* kExternalTestResourcesPath =
50 "third_party/dom_distiller_js/dist/test/data"; 50 "third_party/dom_distiller_js/dist/test/data";
51 // TODO(wychen) Remove filter when crbug.com/471854 is fixed. 51 // TODO(wychen) Remove filter when crbug.com/471854 is fixed.
mdjones 2015/12/16 00:22:38 Remove todo?
wychen 2015/12/16 00:54:00 Done.
52 const char* kTestFilePath = 52 const char* kTestFilePath =
53 "/war/test.html?console_log=0&filter=-*.SchemaOrgParserAccessorTest.*"; 53 "/war/test.html?console_log=0";
mdjones 2015/12/16 00:22:39 I think this fits on the line above.
wychen 2015/12/16 00:54:00 Done.
54 const char* kRunJsTestsJs = 54 const char* kRunJsTestsJs =
55 "(function() {return org.chromium.distiller.JsTestEntry.run();})();"; 55 "(function() {return org.chromium.distiller.JsTestEntry.run();})();";
56 56
57 class DomDistillerJsTest : public content::ContentBrowserTest { 57 class DomDistillerJsTest : public content::ContentBrowserTest {
58 public: 58 public:
59 DomDistillerJsTest() : result_(NULL) {} 59 DomDistillerJsTest() : result_(NULL) {}
60 60
61 // content::ContentBrowserTest: 61 // content::ContentBrowserTest:
62 void SetUpOnMainThread() override { 62 void SetUpOnMainThread() override {
63 AddComponentsResources(); 63 AddComponentsResources();
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
159 // Only print the log if there was an error. 159 // Only print the log if there was an error.
160 if (!success) { 160 if (!success) {
161 ASSERT_TRUE(dict->HasKey("log")); 161 ASSERT_TRUE(dict->HasKey("log"));
162 std::string console_log; 162 std::string console_log;
163 ASSERT_TRUE(dict->GetString("log", &console_log)); 163 ASSERT_TRUE(dict->GetString("log", &console_log));
164 VLOG(0) << "Console log:\n" << console_log; 164 VLOG(0) << "Console log:\n" << console_log;
165 } 165 }
166 } 166 }
167 167
168 } // namespace dom_distiller 168 } // namespace dom_distiller
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698