Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * | 7 * |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 17 matching lines...) Expand all Loading... | |
| 28 | 28 |
| 29 #include "wtf/PassRefPtr.h" | 29 #include "wtf/PassRefPtr.h" |
| 30 #include "wtf/text/WTFString.h" | 30 #include "wtf/text/WTFString.h" |
| 31 | 31 |
| 32 namespace blink { | 32 namespace blink { |
| 33 | 33 |
| 34 class SharedBuffer; | 34 class SharedBuffer; |
| 35 | 35 |
| 36 namespace testing { | 36 namespace testing { |
| 37 | 37 |
| 38 // Note: You may want to use TestingPlatformSupportWithMockScheduler to | |
| 39 // provides runUntilIdle() method that can work with WebURLLoaderMockFactory. | |
| 38 void runPendingTasks(); | 40 void runPendingTasks(); |
| 39 | 41 |
| 40 // Wait for delayed task to complete or timers to fire for |delayMs| | 42 // Waits for delayed task to complete or timers to fire for |delayMs| |
| 41 // milliseconds. | 43 // milliseconds. |
| 42 void runDelayedTasks(double delayMs); | 44 void runDelayedTasks(double delayMs); |
| 43 | 45 |
| 44 String blinkRootDir(); | |
| 45 | |
| 46 PassRefPtr<SharedBuffer> readFromFile(const String& path); | |
| 47 | |
| 48 void enterRunLoop(); | 46 void enterRunLoop(); |
| 49 void exitRunLoop(); | 47 void exitRunLoop(); |
| 50 | 48 |
| 51 void yieldCurrentThread(); | 49 void yieldCurrentThread(); |
| 52 | 50 |
| 51 // Returns Blink top directory as an absolute path, e.g. | |
| 52 // /src/third_party/WebKit. | |
| 53 String blinkRootDir(); | |
| 54 | |
| 55 // Returns test data absolute path for webkit_unit_tests, i.e. | |
| 56 // <blinkRootDir>/Source/web/tests/data/<relativePath>. | |
| 57 // It returns top web test directory if |relativePath| was not specified. | |
|
kinuko
2017/01/27 15:50:40
nit: top web test directory -> the top web test di
Takashi Toyoshima
2017/02/06 08:14:55
Done.
| |
| 58 String webTestDataPath(const String& relativePath = String()); | |
| 59 | |
| 60 // Returns test data absolute path for blink_platform_unittests, i.e. | |
| 61 // <blinkRootDir>/Source/platform/testing/data/<relativePath>. | |
| 62 // It returns top platform test directory if |relativePath| was not specified. | |
|
kinuko
2017/01/27 15:50:40
top ... -> the top ...
Takashi Toyoshima
2017/02/06 08:14:55
Done.
| |
| 63 String platformTestDataPath(const String& relativePath = String()); | |
| 64 | |
| 65 PassRefPtr<SharedBuffer> readFromFile(const String& path); | |
| 66 | |
| 53 } // namespace testing | 67 } // namespace testing |
| 54 } // namespace blink | 68 } // namespace blink |
| 55 | 69 |
| 56 #endif | 70 #endif |
| OLD | NEW |