-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor: Migrate from mockito
to mocktail
in TransactionSigningGateway
#250
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Love it! few minor updates and we're good to merge 👍🏻
dev_dependencies: | ||
flutter_test: | ||
sdk: flutter | ||
lint: 1.8.1 | ||
very_good_analysis: 2.4.0 | ||
mockito: 5.0.14 | ||
mocktail: ^0.3.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let's stick with exact version for mocktail
mocktail: ^0.3.0 | |
mocktail: 0.3.0 |
@@ -1,6 +1,6 @@ | |||
import 'package:cosmos_utils/cosmos_utils.dart'; | |||
import 'package:dartz/dartz.dart'; | |||
import 'package:mockito/mockito.dart'; | |||
import 'package:mocktail/mocktail.dart'; | |||
import 'package:transaction_signing_gateway/model/account_lookup_key.dart'; | |||
import 'package:transaction_signing_gateway/model/private_account_credentials.dart'; | |||
import 'package:transaction_signing_gateway/storage/key_info_storage.dart'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
with mocktail, this mock implementation can be now reduced to:
class KeyInfoStorageMock extends Mock implements KeyInfoStorage {}
@@ -1,5 +1,5 @@ | |||
import 'package:dartz/dartz.dart'; | |||
import 'package:mockito/mockito.dart'; | |||
import 'package:mocktail/mocktail.dart'; | |||
import 'package:transaction_signing_gateway/model/transaction_signing_failure.dart'; | |||
import 'package:transaction_signing_gateway/model/unsigned_transaction.dart'; | |||
import 'package:transaction_signing_gateway/transaction_summary_ui.dart'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same here:
with mocktail, this mock implementation can be now reduced to:
class TransactionSummaryUIMock extends Mock implements TransactionSummaryUI {}
No description provided.