| Index: LayoutTests/fast/js/Future-chain.html
|
| diff --git a/LayoutTests/fast/js/Future-chain.html b/LayoutTests/fast/js/Future-chain.html
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..446bfced122f80caf115b92f99aac2ab0bb5bba6
|
| --- /dev/null
|
| +++ b/LayoutTests/fast/js/Future-chain.html
|
| @@ -0,0 +1,38 @@
|
| +<!DOCTYPE html>
|
| +<html>
|
| +<head>
|
| +<script src="resources/js-test-pre.js"></script>
|
| +</head>
|
| +<body>
|
| +<div id="description"></div>
|
| +<div id="console"></div>
|
| +<script>
|
| +description("Test Future.");
|
| +
|
| +window.jsTestIsAsync = true;
|
| +
|
| +var resolver;
|
| +
|
| +new Future(
|
| + function(newResolver) {
|
| + resolver = newResolver;
|
| + })
|
| + .then(
|
| + function(value) {
|
| + window.value = value;
|
| + shouldBeEqualToString("value", "hello");
|
| + return "world";
|
| + })
|
| + .then(
|
| + function(value) {
|
| + window.value = value;
|
| + shouldBeEqualToString("value", "world");
|
| + finishJSTest();
|
| + });
|
| +
|
| +resolver.accept("hello");
|
| +
|
| +</script>
|
| +<script src="resources/js-test-post.js"></script>
|
| +</body>
|
| +</html>
|
|
|