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 <stddef.h> | 5 #include <stddef.h> |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "base/base_paths.h" | 9 #include "base/base_paths.h" |
10 #include "base/files/file_enumerator.h" | 10 #include "base/files/file_enumerator.h" |
(...skipping 377 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
388 } | 388 } |
389 | 389 |
390 IN_PROC_BROWSER_TEST_F(PDFExtensionTest, ZoomManager) { | 390 IN_PROC_BROWSER_TEST_F(PDFExtensionTest, ZoomManager) { |
391 RunTestsInFile("zoom_manager_test.js", "test.pdf"); | 391 RunTestsInFile("zoom_manager_test.js", "test.pdf"); |
392 } | 392 } |
393 | 393 |
394 IN_PROC_BROWSER_TEST_F(PDFExtensionTest, GestureDetector) { | 394 IN_PROC_BROWSER_TEST_F(PDFExtensionTest, GestureDetector) { |
395 RunTestsInFile("gesture_detector_test.js", "test.pdf"); | 395 RunTestsInFile("gesture_detector_test.js", "test.pdf"); |
396 } | 396 } |
397 | 397 |
398 IN_PROC_BROWSER_TEST_F(PDFExtensionTest, TouchHandling) { | |
399 RunTestsInFile("touch_handling_test.js", "test.pdf"); | |
400 } | |
401 | |
402 IN_PROC_BROWSER_TEST_F(PDFExtensionTest, Elements) { | 398 IN_PROC_BROWSER_TEST_F(PDFExtensionTest, Elements) { |
403 // Although this test file does not require a PDF to be loaded, loading the | 399 // Although this test file does not require a PDF to be loaded, loading the |
404 // elements without loading a PDF is difficult. | 400 // elements without loading a PDF is difficult. |
405 RunTestsInFile("material_elements_test.js", "test.pdf"); | 401 RunTestsInFile("material_elements_test.js", "test.pdf"); |
406 } | 402 } |
407 | 403 |
408 IN_PROC_BROWSER_TEST_F(PDFExtensionTest, ToolbarManager) { | 404 IN_PROC_BROWSER_TEST_F(PDFExtensionTest, ToolbarManager) { |
409 RunTestsInFile("toolbar_manager_test.js", "test.pdf"); | 405 RunTestsInFile("toolbar_manager_test.js", "test.pdf"); |
410 } | 406 } |
411 | 407 |
(...skipping 609 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1021 IN_PROC_BROWSER_TEST_F(PDFExtensionTest, OpenFromFTP) { | 1017 IN_PROC_BROWSER_TEST_F(PDFExtensionTest, OpenFromFTP) { |
1022 net::SpawnedTestServer ftp_server( | 1018 net::SpawnedTestServer ftp_server( |
1023 net::SpawnedTestServer::TYPE_FTP, net::SpawnedTestServer::kLocalhost, | 1019 net::SpawnedTestServer::TYPE_FTP, net::SpawnedTestServer::kLocalhost, |
1024 base::FilePath(FILE_PATH_LITERAL("chrome/test/data/pdf"))); | 1020 base::FilePath(FILE_PATH_LITERAL("chrome/test/data/pdf"))); |
1025 ASSERT_TRUE(ftp_server.Start()); | 1021 ASSERT_TRUE(ftp_server.Start()); |
1026 | 1022 |
1027 GURL url(ftp_server.GetURL("/test.pdf")); | 1023 GURL url(ftp_server.GetURL("/test.pdf")); |
1028 ASSERT_TRUE(LoadPdf(url)); | 1024 ASSERT_TRUE(LoadPdf(url)); |
1029 EXPECT_EQ(base::ASCIIToUTF16("test.pdf"), GetActiveWebContents()->GetTitle()); | 1025 EXPECT_EQ(base::ASCIIToUTF16("test.pdf"), GetActiveWebContents()->GetTitle()); |
1030 } | 1026 } |
OLD | NEW |