| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "content/test/layout_browsertest.h" | 5 #include "content/test/layout_browsertest.h" |
| 6 | 6 |
| 7 class BlobLayoutTest : public InProcessBrowserLayoutTest { | 7 class BlobLayoutTest : public InProcessBrowserLayoutTest { |
| 8 public: | 8 public: |
| 9 BlobLayoutTest() : | 9 BlobLayoutTest() : |
| 10 InProcessBrowserLayoutTest( | 10 InProcessBrowserLayoutTest( |
| 11 FilePath(), | 11 FilePath(), |
| 12 FilePath(FILE_PATH_LITERAL("fast/files")).NormalizePathSeparators()) { | 12 FilePath(FILE_PATH_LITERAL("fast/files")).NormalizePathSeparators()) { |
| 13 } | 13 } |
| 14 | |
| 15 virtual void SetUpInProcessBrowserTestFixture() OVERRIDE { | |
| 16 InProcessBrowserLayoutTest::SetUpInProcessBrowserTestFixture(); | |
| 17 AddResourceForLayoutTest( | |
| 18 FilePath(FILE_PATH_LITERAL("fast/js")).NormalizePathSeparators(), | |
| 19 FilePath(FILE_PATH_LITERAL("resources"))); | |
| 20 } | |
| 21 | |
| 22 void RunLayoutTests(const char* file_names[]) { | |
| 23 for (size_t i = 0; file_names[i]; i++) | |
| 24 RunLayoutTest(file_names[i]); | |
| 25 } | |
| 26 }; | 14 }; |
| 27 | 15 |
| 28 namespace { | 16 IN_PROC_BROWSER_TEST_F(BlobLayoutTest, SliceTests) { |
| 29 | 17 RunLayoutTest("blob-slice-test.html"); |
| 30 static const char* kSliceTests[] = { | |
| 31 "blob-slice-test.html", | |
| 32 NULL | |
| 33 }; | |
| 34 | |
| 35 } | 18 } |
| 36 | |
| 37 IN_PROC_BROWSER_TEST_F(BlobLayoutTest, SliceTests) { | |
| 38 RunLayoutTests(kSliceTests); | |
| 39 } | |
| OLD | NEW |