Skip to content
This repository was archived by the owner on Feb 22, 2023. It is now read-only.
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Added a failing test case (for enum value -3)
  • Loading branch information
impure committed Dec 21, 2020
commit 6f7ea347ee64aa7047d2b668ef9158587426fc55
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,15 @@ void main() {
});
});

// Make sure that the enum values are supported and that the converter call
// does not fail
group('enumValues', () {
test('enum -3', () async {
BillingResponseConverter converter = BillingResponseConverter();
converter.fromJson(-3);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: Could you combine these different assertions into one test? These are different statements, but it's really testing that all the expected values are supported. So I think it makes sense to put them in one test case instead of having one per enum value.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, done.

});
});

group('startConnection', () {
final String methodName =
'BillingClient#startConnection(BillingClientStateListener)';
Expand Down