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

Unified Diff: test/codegen_expected/language/flatten_test_11_multi.js

Issue 2201973002: fix optional params to mock methods, allow all signatures (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: fix getters and setters Created 4 years, 5 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: test/codegen_expected/language/flatten_test_11_multi.js
diff --git a/test/codegen_expected/language/flatten_test_11_multi.js b/test/codegen_expected/language/flatten_test_11_multi.js
index 6cfc7d20b29fe0c26fbe4591d7cc3b738a62faec..171a46db5824c061b68510823510be47368e74c4 100644
--- a/test/codegen_expected/language/flatten_test_11_multi.js
+++ b/test/codegen_expected/language/flatten_test_11_multi.js
@@ -18,37 +18,37 @@ dart_library.library('language/flatten_test_11_multi', null, /* Imports */[
return super.noSuchMethod(invocation);
}
wait(T) {
- return (futures, opts) => {
- return async.Future$(core.List$(T))._check(this.noSuchMethod(new dart.InvocationImpl('wait', [futures], {namedArguments: opts, isMethod: true})));
+ return (...args) => {
+ return async.Future$(core.List$(T))._check(this.noSuchMethod(new dart.InvocationImpl('wait', args, {namedArguments: dart.extractNamedArgs(args), isMethod: true})));
};
}
any(T) {
- return futures => {
- return async.Future$(T)._check(this.noSuchMethod(new dart.InvocationImpl('any', [futures], {isMethod: true})));
+ return (...args) => {
+ return async.Future$(T)._check(this.noSuchMethod(new dart.InvocationImpl('any', args, {isMethod: true})));
};
}
- forEach(input, f) {
- return async.Future._check(this.noSuchMethod(new dart.InvocationImpl('forEach', [input, f], {isMethod: true})));
+ forEach(...args) {
+ return async.Future._check(this.noSuchMethod(new dart.InvocationImpl('forEach', args, {isMethod: true})));
}
- doWhile(f) {
- return async.Future._check(this.noSuchMethod(new dart.InvocationImpl('doWhile', [f], {isMethod: true})));
+ doWhile(...args) {
+ return async.Future._check(this.noSuchMethod(new dart.InvocationImpl('doWhile', args, {isMethod: true})));
}
then(S) {
- return (onValue, opts) => {
- return async.Future$(S)._check(this.noSuchMethod(new dart.InvocationImpl('then', [onValue], {namedArguments: opts, isMethod: true})));
+ return (...args) => {
+ return async.Future$(S)._check(this.noSuchMethod(new dart.InvocationImpl('then', args, {namedArguments: dart.extractNamedArgs(args), isMethod: true})));
};
}
- catchError(onError, opts) {
- return FutureOfT()._check(this.noSuchMethod(new dart.InvocationImpl('catchError', [onError], {namedArguments: opts, isMethod: true})));
+ catchError(...args) {
+ return FutureOfT()._check(this.noSuchMethod(new dart.InvocationImpl('catchError', args, {namedArguments: dart.extractNamedArgs(args), isMethod: true})));
}
- whenComplete(action) {
- return FutureOfT()._check(this.noSuchMethod(new dart.InvocationImpl('whenComplete', [action], {isMethod: true})));
+ whenComplete(...args) {
+ return FutureOfT()._check(this.noSuchMethod(new dart.InvocationImpl('whenComplete', args, {isMethod: true})));
}
- asStream() {
- return StreamOfT()._check(this.noSuchMethod(new dart.InvocationImpl('asStream', [], {isMethod: true})));
+ asStream(...args) {
+ return StreamOfT()._check(this.noSuchMethod(new dart.InvocationImpl('asStream', args, {isMethod: true})));
}
- timeout(timeLimit, opts) {
- return FutureOfT()._check(this.noSuchMethod(new dart.InvocationImpl('timeout', [timeLimit], {namedArguments: opts, isMethod: true})));
+ timeout(...args) {
+ return FutureOfT()._check(this.noSuchMethod(new dart.InvocationImpl('timeout', args, {namedArguments: dart.extractNamedArgs(args), isMethod: true})));
}
get _nullFuture() {
return async._Future._check(this.noSuchMethod(new dart.InvocationImpl('_nullFuture', [], {isGetter: true})));
@@ -68,37 +68,37 @@ dart_library.library('language/flatten_test_11_multi', null, /* Imports */[
return super.noSuchMethod(invocation);
}
wait(T) {
- return (futures, opts) => {
- return async.Future$(core.List$(T))._check(this.noSuchMethod(new dart.InvocationImpl('wait', [futures], {namedArguments: opts, isMethod: true})));
+ return (...args) => {
+ return async.Future$(core.List$(T))._check(this.noSuchMethod(new dart.InvocationImpl('wait', args, {namedArguments: dart.extractNamedArgs(args), isMethod: true})));
};
}
any(T) {
- return futures => {
- return async.Future$(T)._check(this.noSuchMethod(new dart.InvocationImpl('any', [futures], {isMethod: true})));
+ return (...args) => {
+ return async.Future$(T)._check(this.noSuchMethod(new dart.InvocationImpl('any', args, {isMethod: true})));
};
}
- forEach(input, f) {
- return async.Future._check(this.noSuchMethod(new dart.InvocationImpl('forEach', [input, f], {isMethod: true})));
+ forEach(...args) {
+ return async.Future._check(this.noSuchMethod(new dart.InvocationImpl('forEach', args, {isMethod: true})));
}
- doWhile(f) {
- return async.Future._check(this.noSuchMethod(new dart.InvocationImpl('doWhile', [f], {isMethod: true})));
+ doWhile(...args) {
+ return async.Future._check(this.noSuchMethod(new dart.InvocationImpl('doWhile', args, {isMethod: true})));
}
then(S) {
- return (onValue, opts) => {
- return async.Future$(S)._check(this.noSuchMethod(new dart.InvocationImpl('then', [onValue], {namedArguments: opts, isMethod: true})));
+ return (...args) => {
+ return async.Future$(S)._check(this.noSuchMethod(new dart.InvocationImpl('then', args, {namedArguments: dart.extractNamedArgs(args), isMethod: true})));
};
}
- catchError(onError, opts) {
- return FutureOfFixedPointOfT()._check(this.noSuchMethod(new dart.InvocationImpl('catchError', [onError], {namedArguments: opts, isMethod: true})));
+ catchError(...args) {
+ return FutureOfFixedPointOfT()._check(this.noSuchMethod(new dart.InvocationImpl('catchError', args, {namedArguments: dart.extractNamedArgs(args), isMethod: true})));
}
- whenComplete(action) {
- return FutureOfFixedPointOfT()._check(this.noSuchMethod(new dart.InvocationImpl('whenComplete', [action], {isMethod: true})));
+ whenComplete(...args) {
+ return FutureOfFixedPointOfT()._check(this.noSuchMethod(new dart.InvocationImpl('whenComplete', args, {isMethod: true})));
}
- asStream() {
- return StreamOfFixedPointOfT()._check(this.noSuchMethod(new dart.InvocationImpl('asStream', [], {isMethod: true})));
+ asStream(...args) {
+ return StreamOfFixedPointOfT()._check(this.noSuchMethod(new dart.InvocationImpl('asStream', args, {isMethod: true})));
}
- timeout(timeLimit, opts) {
- return FutureOfFixedPointOfT()._check(this.noSuchMethod(new dart.InvocationImpl('timeout', [timeLimit], {namedArguments: opts, isMethod: true})));
+ timeout(...args) {
+ return FutureOfFixedPointOfT()._check(this.noSuchMethod(new dart.InvocationImpl('timeout', args, {namedArguments: dart.extractNamedArgs(args), isMethod: true})));
}
get _nullFuture() {
return async._Future._check(this.noSuchMethod(new dart.InvocationImpl('_nullFuture', [], {isGetter: true})));

Powered by Google App Engine
This is Rietveld 408576698