Commit c516066
committed
store test: Add await for checking Future.throws.
These tests actually worked as expected, even though we didn't await
for the Future returned by FutureChecks.throws.
This is because checks ensure that the asychronous expectations are
complete before the test ends.
Nonetheless, we should use await so that our intention is explicit
(i.e. the future completes with an error as opposed to the future
never completes and can't be awaited).
See also:
https://github.com/dart-lang/test/tree/master/pkgs/checks#checking-asynchronous-expectations
Signed-off-by: Zixuan James Li <zixuan@zulip.com>1 parent fa460f9 commit c516066
1 file changed
+3
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
153 | 153 | | |
154 | 154 | | |
155 | 155 | | |
156 | | - | |
| 156 | + | |
157 | 157 | | |
158 | | - | |
| 158 | + | |
159 | 159 | | |
160 | | - | |
| 160 | + | |
161 | 161 | | |
162 | 162 | | |
163 | 163 | | |
| |||
0 commit comments