Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(34)

Unified Diff: third_party/WebKit/LayoutTests/http/tests/geofencing/service-not-available.html

Issue 1926813004: Replace assert_promise_rejects with upstream promise_rejects. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove all testharness-helpers.js references Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/http/tests/geofencing/service-not-available.html
diff --git a/third_party/WebKit/LayoutTests/http/tests/geofencing/service-not-available.html b/third_party/WebKit/LayoutTests/http/tests/geofencing/service-not-available.html
index 88cf994521534f95f4db7bcb67137f81b0c42af6..84065ad999077710e2e08f258a1c3854c1f81ce2 100644
--- a/third_party/WebKit/LayoutTests/http/tests/geofencing/service-not-available.html
+++ b/third_party/WebKit/LayoutTests/http/tests/geofencing/service-not-available.html
@@ -2,7 +2,6 @@
<title>Tests that all geofencing methods exposed on a service worker registration always reject if no geofencing service is available.</title>
<script src="../resources/testharness.js"></script>
<script src="../resources/testharnessreport.js"></script>
-<script src="../resources/testharness-helpers.js"></script>
<script src="../serviceworker/resources/test-helpers.js"></script>
<script>
var sw_url = 'resources/emptyworker.js';
@@ -11,34 +10,37 @@ var sw_scope = 'resources/service-worker-scope' + window.location.pathname;
testRunner.setGeofencingMockProvider(false);
promise_test(function(test) {
- return assert_promise_rejects(
+ return promise_rejects(
+ test,
+ 'AbortError',
service_worker_unregister_and_register(test, sw_url, sw_scope + '/register')
.then(function(r) {
return r.geofencing.registerRegion(
new CircularGeofencingRegion({latitude: 37.421999,
longitude: -122.084015}));
}),
- 'AbortError',
'registerRegion should fail with an AbortError');
}, 'registerRegion should fail');
promise_test(function(test) {
- return assert_promise_rejects(
+ return promise_rejects(
+ test,
+ 'AbortError',
service_worker_unregister_and_register(test, sw_url, sw_scope + '/unregister')
.then(function(r) {
return r.geofencing.unregisterRegion('');
}),
- 'AbortError',
'unregisterRegion should fail with an AbortError');
}, 'unregisterRegion should fail');
promise_test(function(test) {
- return assert_promise_rejects(
+ return promise_rejects(
+ test,
+ 'AbortError',
service_worker_unregister_and_register(test, sw_url, sw_scope + '/getregions')
.then(function(r) {
return r.geofencing.getRegisteredRegions();
}),
- 'AbortError',
'getRegisteredRegions should fail with an AbortError');
}, 'getRegisteredRegions should fail');

Powered by Google App Engine
This is Rietveld 408576698