| Index: tests/corelib/future_test.dart
|
| diff --git a/tests/corelib/future_test.dart b/tests/corelib/future_test.dart
|
| index 1916dddfeddb9e0b68c331cf44b5835a13689713..f4e512c45d81339a310a6d11cfbaee48fd26a739 100644
|
| --- a/tests/corelib/future_test.dart
|
| +++ b/tests/corelib/future_test.dart
|
| @@ -351,6 +351,19 @@ testCallStackIsCapturedIfChainCallbackThrows() {
|
| Expect.isNotNull(chained.stackTrace);
|
| }
|
|
|
| +testCallStackIsPreservedIfExceptionIsRethrownInTransformException() {
|
| + final completer = new Completer();
|
| + var chained = completer.future.chain((_) {
|
| + throw 'whoops!';
|
| + });
|
| + var transformed = chained.transformException((e) {
|
| + throw e;
|
| + });
|
| +
|
| + completer.complete('blah');
|
| + Expect.equals(transformed.stackTrace, chained.stackTrace);
|
| +}
|
| +
|
| // Tests for mixed usage of [onComplete], [then], and [handleException]
|
|
|
| testCompleteWithCompletionAndSuccessHandlers() {
|
| @@ -677,6 +690,7 @@ main() {
|
| testCallStackReturnsCallstackPassedToCompleteException();
|
| testCallStackIsCapturedIfTransformCallbackThrows();
|
| testCallStackIsCapturedIfChainCallbackThrows();
|
| + testCallStackIsPreservedIfExceptionIsRethrownInTransformException();
|
| testCompleteWithCompletionAndSuccessHandlers();
|
| testExceptionWithCompletionAndSuccessHandlers();
|
| testExceptionWithCompletionAndSuccessAndExceptionHandlers();
|
|
|