| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 // Browser test for basic Chrome OS file manager functionality: | 5 // Browser test for basic Chrome OS file manager functionality: |
| 6 // - The file list is updated when a file is added externally to the Downloads | 6 // - The file list is updated when a file is added externally to the Downloads |
| 7 // folder. | 7 // folder. |
| 8 // - Selecting a file and copy-pasting it with the keyboard copies the file. | 8 // - Selecting a file and copy-pasting it with the keyboard copies the file. |
| 9 // - Selecting a file and pressing delete deletes it. | 9 // - Selecting a file and pressing delete deletes it. |
| 10 | 10 |
| (...skipping 729 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 740 public FileManagerBrowserTestBase, | 740 public FileManagerBrowserTestBase, |
| 741 public ::testing::WithParamInterface<TestParameter> { | 741 public ::testing::WithParamInterface<TestParameter> { |
| 742 virtual GuestMode GetGuestModeParam() const OVERRIDE { | 742 virtual GuestMode GetGuestModeParam() const OVERRIDE { |
| 743 return std::tr1::get<0>(GetParam()); | 743 return std::tr1::get<0>(GetParam()); |
| 744 } | 744 } |
| 745 virtual const char* GetTestCaseNameParam() const OVERRIDE { | 745 virtual const char* GetTestCaseNameParam() const OVERRIDE { |
| 746 return std::tr1::get<1>(GetParam()); | 746 return std::tr1::get<1>(GetParam()); |
| 747 } | 747 } |
| 748 }; | 748 }; |
| 749 | 749 |
| 750 // http://crbug.com/400892 | 750 IN_PROC_BROWSER_TEST_P(FileManagerBrowserTest, Test) { |
| 751 IN_PROC_BROWSER_TEST_P(FileManagerBrowserTest, DISABLED_Test) { | |
| 752 StartTest(); | 751 StartTest(); |
| 753 } | 752 } |
| 754 | 753 |
| 755 // Unlike TEST/TEST_F, which are macros that expand to further macros, | 754 // Unlike TEST/TEST_F, which are macros that expand to further macros, |
| 756 // INSTANTIATE_TEST_CASE_P is a macro that expands directly to code that | 755 // INSTANTIATE_TEST_CASE_P is a macro that expands directly to code that |
| 757 // stringizes the arguments. As a result, macros passed as parameters (such as | 756 // stringizes the arguments. As a result, macros passed as parameters (such as |
| 758 // prefix or test_case_name) will not be expanded by the preprocessor. To work | 757 // prefix or test_case_name) will not be expanded by the preprocessor. To work |
| 759 // around this, indirect the macro for INSTANTIATE_TEST_CASE_P, so that the | 758 // around this, indirect the macro for INSTANTIATE_TEST_CASE_P, so that the |
| 760 // pre-processor will expand macros such as MAYBE_test_name before | 759 // pre-processor will expand macros such as MAYBE_test_name before |
| 761 // instantiating the test. | 760 // instantiating the test. |
| (...skipping 15 matching lines...) Expand all Loading... |
| 777 TestParameter(NOT_IN_GUEST_MODE, "fileDisplayMtp"))); | 776 TestParameter(NOT_IN_GUEST_MODE, "fileDisplayMtp"))); |
| 778 | 777 |
| 779 // http://crbug.com/327719 | 778 // http://crbug.com/327719 |
| 780 WRAPPED_INSTANTIATE_TEST_CASE_P( | 779 WRAPPED_INSTANTIATE_TEST_CASE_P( |
| 781 DISABLED_OpenZipFiles, | 780 DISABLED_OpenZipFiles, |
| 782 FileManagerBrowserTest, | 781 FileManagerBrowserTest, |
| 783 ::testing::Values(TestParameter(IN_GUEST_MODE, "zipOpenDownloads"), | 782 ::testing::Values(TestParameter(IN_GUEST_MODE, "zipOpenDownloads"), |
| 784 TestParameter(NOT_IN_GUEST_MODE, "zipOpenDownloads"), | 783 TestParameter(NOT_IN_GUEST_MODE, "zipOpenDownloads"), |
| 785 TestParameter(NOT_IN_GUEST_MODE, "zipOpenDrive"))); | 784 TestParameter(NOT_IN_GUEST_MODE, "zipOpenDrive"))); |
| 786 | 785 |
| 787 // Slow tests are disabled on debug build. http://crbug.com/327719 | 786 // http://crbug.com/400892 |
| 788 #if !defined(NDEBUG) | |
| 789 #define MAYBE_OpenVideoFiles DISABLED_OpenVideoFiles | |
| 790 #else | |
| 791 #define MAYBE_OpenVideoFiles OpenVideoFiles | |
| 792 #endif | |
| 793 WRAPPED_INSTANTIATE_TEST_CASE_P( | 787 WRAPPED_INSTANTIATE_TEST_CASE_P( |
| 794 MAYBE_OpenVideoFiles, | 788 DISABLED_OpenVideoFiles, |
| 795 FileManagerBrowserTest, | 789 FileManagerBrowserTest, |
| 796 ::testing::Values(TestParameter(IN_GUEST_MODE, "videoOpenDownloads"), | 790 ::testing::Values(TestParameter(IN_GUEST_MODE, "videoOpenDownloads"), |
| 797 TestParameter(NOT_IN_GUEST_MODE, "videoOpenDownloads"), | 791 TestParameter(NOT_IN_GUEST_MODE, "videoOpenDownloads"), |
| 798 TestParameter(NOT_IN_GUEST_MODE, "videoOpenDrive"))); | 792 TestParameter(NOT_IN_GUEST_MODE, "videoOpenDrive"))); |
| 799 | 793 |
| 800 // Slow tests are disabled on debug build. http://crbug.com/327719 | 794 // http://crbug.com/401674 |
| 801 #if !defined(NDEBUG) | |
| 802 #define MAYBE_OpenAudioFiles DISABLED_OpenAudioFiles | |
| 803 #else | |
| 804 #define MAYBE_OpenAudioFiles OpenAudioFiles | |
| 805 #endif | |
| 806 WRAPPED_INSTANTIATE_TEST_CASE_P( | 795 WRAPPED_INSTANTIATE_TEST_CASE_P( |
| 807 MAYBE_OpenAudioFiles, | 796 DISABLED_OpenAudioFiles, |
| 808 FileManagerBrowserTest, | 797 FileManagerBrowserTest, |
| 809 ::testing::Values( | 798 ::testing::Values( |
| 810 TestParameter(IN_GUEST_MODE, "audioOpenDownloads"), | 799 TestParameter(IN_GUEST_MODE, "audioOpenDownloads"), |
| 811 TestParameter(NOT_IN_GUEST_MODE, "audioOpenDownloads"), | 800 TestParameter(NOT_IN_GUEST_MODE, "audioOpenDownloads"), |
| 812 TestParameter(NOT_IN_GUEST_MODE, "audioOpenDrive"), | 801 TestParameter(NOT_IN_GUEST_MODE, "audioOpenDrive"), |
| 813 TestParameter(NOT_IN_GUEST_MODE, "audioAutoAdvanceDrive"), | 802 TestParameter(NOT_IN_GUEST_MODE, "audioAutoAdvanceDrive"), |
| 814 TestParameter(NOT_IN_GUEST_MODE, "audioRepeatSingleFileDrive"), | 803 TestParameter(NOT_IN_GUEST_MODE, "audioRepeatSingleFileDrive"), |
| 815 TestParameter(NOT_IN_GUEST_MODE, "audioNoRepeatSingleFileDrive"), | 804 TestParameter(NOT_IN_GUEST_MODE, "audioNoRepeatSingleFileDrive"), |
| 816 TestParameter(NOT_IN_GUEST_MODE, "audioRepeatMultipleFileDrive"), | 805 TestParameter(NOT_IN_GUEST_MODE, "audioRepeatMultipleFileDrive"), |
| 817 TestParameter(NOT_IN_GUEST_MODE, "audioNoRepeatMultipleFileDrive"))); | 806 TestParameter(NOT_IN_GUEST_MODE, "audioNoRepeatMultipleFileDrive"))); |
| (...skipping 635 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1453 } | 1442 } |
| 1454 | 1443 |
| 1455 IN_PROC_BROWSER_TEST_F(GalleryBrowserTest, ExposureImageOnDrive) { | 1444 IN_PROC_BROWSER_TEST_F(GalleryBrowserTest, ExposureImageOnDrive) { |
| 1456 AddScript("gallery/photo_editor.js"); | 1445 AddScript("gallery/photo_editor.js"); |
| 1457 set_test_case_name("exposureImageOnDrive"); | 1446 set_test_case_name("exposureImageOnDrive"); |
| 1458 StartTest(); | 1447 StartTest(); |
| 1459 } | 1448 } |
| 1460 | 1449 |
| 1461 } // namespace | 1450 } // namespace |
| 1462 } // namespace file_manager | 1451 } // namespace file_manager |
| OLD | NEW |