mirror of
https://github.com/dart-lang/sdk
synced 2024-09-16 01:45:06 +00:00
[tests] Fix type of stream getter in test
The focus event stream is typed to be non-nullable. Updated the return of the function passed to reduce in the "_2" version as well to keep them consistent. Change-Id: Ic1ae2e027c184d751549c989d60924360139fd5c Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/154140 Reviewed-by: Srujan Gaddam <srujzs@google.com> Reviewed-by: Nicholas Shahan <nshahan@google.com> Commit-Queue: Nicholas Shahan <nshahan@google.com>
This commit is contained in:
parent
6547f741b6
commit
cd9a206d55
|
@ -15,7 +15,7 @@ class StreamHelper {
|
|||
}
|
||||
|
||||
Element get element => _a;
|
||||
Stream<Event?> get stream => _a.onFocus;
|
||||
Stream<Event> get stream => _a.onFocus;
|
||||
|
||||
// Causes an event on a to be fired.
|
||||
void pulse() {
|
||||
|
@ -193,7 +193,7 @@ main() {
|
|||
});
|
||||
|
||||
test('reduce', () {
|
||||
stream.reduce((a, b) => null).then((_) {});
|
||||
stream.reduce((a, b) => a).then((_) {});
|
||||
});
|
||||
|
||||
test('fold', () {
|
||||
|
|
|
@ -189,7 +189,7 @@ main() {
|
|||
});
|
||||
|
||||
test('reduce', () {
|
||||
stream.reduce((a, b) => null).then((_) {});
|
||||
stream.reduce((a, b) => a).then((_) {});
|
||||
});
|
||||
|
||||
test('fold', () {
|
||||
|
|
Loading…
Reference in a new issue