Index: LayoutTests/fast/js/Promise-catch.html |
diff --git a/LayoutTests/fast/js/Promise-catch.html b/LayoutTests/fast/js/Promise-catch.html |
deleted file mode 100644 |
index a7361f8fb97cab78180a79a6023254b200de088b..0000000000000000000000000000000000000000 |
--- a/LayoutTests/fast/js/Promise-catch.html |
+++ /dev/null |
@@ -1,52 +0,0 @@ |
-<!DOCTYPE html> |
-<html> |
-<head> |
-<script src="../../resources/js-test.js"></script> |
-</head> |
-<body> |
-<div id="description"></div> |
-<div id="console"></div> |
-<script> |
-description('Test Promise.'); |
- |
-window.jsTestIsAsync = true; |
-var reject; |
- |
-var firstPromise = new Promise(function(_, newReject) { |
- window.thisInInit = this; |
- reject = newReject; |
-}); |
- |
-var secondPromise = firstPromise.catch(function(result) { |
- window.thisInFulfillCallback = this; |
- shouldBeFalse('thisInFulfillCallback === firstPromise'); |
- shouldBeFalse('thisInFulfillCallback === secondPromise'); |
- shouldBeTrue('thisInFulfillCallback === window'); |
- window.result = result; |
- shouldBeEqualToString('result', 'hello'); |
- return 'bye'; |
-}); |
- |
-secondPromise.then(function(result) { |
- window.result = result; |
- shouldBeEqualToString('result', 'bye'); |
- testPassed('fulfilled'); |
- finishJSTest(); |
-}, function() { |
- testFailed('rejected'); |
- finishJSTest(); |
-}, function() { |
-}); |
- |
-shouldBeFalse('thisInInit === firstPromise'); |
-shouldBeTrue('thisInInit === window'); |
-shouldBeTrue('firstPromise instanceof Promise'); |
-shouldBeTrue('secondPromise instanceof Promise'); |
- |
-shouldThrow('firstPromise.catch(null)', '"TypeError: onRejected must be a function or undefined"'); |
-shouldThrow('firstPromise.catch(37)', '"TypeError: onRejected must be a function or undefined"'); |
- |
-reject('hello'); |
-</script> |
-</body> |
-</html> |