| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 <string.h> | 5 #include <string.h> |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/guid.h" | 8 #include "base/guid.h" |
| 9 #include "base/path_service.h" | 9 #include "base/path_service.h" |
| 10 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 73 page->set_url(page_url); | 73 page->set_url(page_url); |
| 74 } | 74 } |
| 75 return entry; | 75 return entry; |
| 76 } | 76 } |
| 77 | 77 |
| 78 } // namespace | 78 } // namespace |
| 79 | 79 |
| 80 class DomDistillerViewerSourceBrowserTest : public InProcessBrowserTest { | 80 class DomDistillerViewerSourceBrowserTest : public InProcessBrowserTest { |
| 81 public: | 81 public: |
| 82 DomDistillerViewerSourceBrowserTest() {} | 82 DomDistillerViewerSourceBrowserTest() {} |
| 83 virtual ~DomDistillerViewerSourceBrowserTest() {} | 83 ~DomDistillerViewerSourceBrowserTest() override {} |
| 84 | 84 |
| 85 void SetUpOnMainThread() override { | 85 void SetUpOnMainThread() override { |
| 86 database_model_ = new FakeDB<ArticleEntry>::EntryMap; | 86 database_model_ = new FakeDB<ArticleEntry>::EntryMap; |
| 87 } | 87 } |
| 88 | 88 |
| 89 void TearDownOnMainThread() override { delete database_model_; } | 89 void TearDownOnMainThread() override { delete database_model_; } |
| 90 | 90 |
| 91 void SetUpCommandLine(CommandLine* command_line) override { | 91 void SetUpCommandLine(CommandLine* command_line) override { |
| 92 command_line->AppendSwitch(switches::kEnableDomDistiller); | 92 command_line->AppendSwitch(switches::kEnableDomDistiller); |
| 93 } | 93 } |
| (...skipping 261 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 355 EXPECT_EQ("dark sans-serif", result); | 355 EXPECT_EQ("dark sans-serif", result); |
| 356 | 356 |
| 357 distilled_page_prefs->SetFontFamily(DistilledPagePrefs::SERIF); | 357 distilled_page_prefs->SetFontFamily(DistilledPagePrefs::SERIF); |
| 358 base::RunLoop().RunUntilIdle(); | 358 base::RunLoop().RunUntilIdle(); |
| 359 EXPECT_TRUE( | 359 EXPECT_TRUE( |
| 360 content::ExecuteScriptAndExtractString(contents, kGetBodyClass, &result)); | 360 content::ExecuteScriptAndExtractString(contents, kGetBodyClass, &result)); |
| 361 EXPECT_EQ("dark serif", result); | 361 EXPECT_EQ("dark serif", result); |
| 362 } | 362 } |
| 363 | 363 |
| 364 } // namespace dom_distiller | 364 } // namespace dom_distiller |
| OLD | NEW |