Skip to content

Commit

Permalink
Add missing await keywords to client test
Browse files Browse the repository at this point in the history
  • Loading branch information
achilleasa committed Jun 4, 2021
1 parent 8f6273a commit 34a60f5
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions test/lib/client_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -68,18 +68,19 @@ main({bool enableLogger = true}) {
}
});

test("should be able to close a client connection after re-opening", () async {
test("should be able to close a client connection after re-opening",
() async {
client = Client();
await client.connect();
Future firstClose = client.close();
firstClose.then((_) async {
await client.connect();
Future secondClose = client.close();
secondClose.then((_) {
expect(identical(firstClose, secondClose), false);
});

await firstClose.then((_) async {
await client.connect();
Future secondClose = client.close();

await secondClose.then((_) {
expect(identical(firstClose, secondClose), false);
});
});
});
});
Expand Down

0 comments on commit 34a60f5

Please sign in to comment.