mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2024-12-22 11:29:23 +00:00
add ordinal tx subtype and clean up build runner issues
This commit is contained in:
parent
bf2331de76
commit
7c990f4f8f
16 changed files with 1210 additions and 3471 deletions
|
@ -254,5 +254,6 @@ enum TransactionSubType {
|
|||
ethToken, // eth token
|
||||
cashFusion,
|
||||
sparkMint, // firo specific
|
||||
sparkSpend; // firo specific
|
||||
sparkSpend, // firo specific
|
||||
ordinal;
|
||||
}
|
||||
|
|
|
@ -367,6 +367,7 @@ const _TransactionsubTypeEnumValueMap = {
|
|||
'cashFusion': 5,
|
||||
'sparkMint': 6,
|
||||
'sparkSpend': 7,
|
||||
'ordinal': 8,
|
||||
};
|
||||
const _TransactionsubTypeValueEnumMap = {
|
||||
0: TransactionSubType.none,
|
||||
|
@ -377,6 +378,7 @@ const _TransactionsubTypeValueEnumMap = {
|
|||
5: TransactionSubType.cashFusion,
|
||||
6: TransactionSubType.sparkMint,
|
||||
7: TransactionSubType.sparkSpend,
|
||||
8: TransactionSubType.ordinal,
|
||||
};
|
||||
const _TransactiontypeEnumValueMap = {
|
||||
'outgoing': 0,
|
||||
|
|
|
@ -388,6 +388,7 @@ const _TransactionV2subTypeEnumValueMap = {
|
|||
'cashFusion': 5,
|
||||
'sparkMint': 6,
|
||||
'sparkSpend': 7,
|
||||
'ordinal': 8,
|
||||
};
|
||||
const _TransactionV2subTypeValueEnumMap = {
|
||||
0: TransactionSubType.none,
|
||||
|
@ -398,6 +399,7 @@ const _TransactionV2subTypeValueEnumMap = {
|
|||
5: TransactionSubType.cashFusion,
|
||||
6: TransactionSubType.sparkMint,
|
||||
7: TransactionSubType.sparkSpend,
|
||||
8: TransactionSubType.ordinal,
|
||||
};
|
||||
const _TransactionV2typeEnumValueMap = {
|
||||
'outgoing': 0,
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
import 'package:mockito/annotations.dart';
|
||||
import 'package:stackwallet/services/coins/coin_service.dart';
|
||||
import 'package:stackwallet/services/locale_service.dart';
|
||||
import 'package:stackwallet/services/node_service.dart';
|
||||
import 'package:stackwallet/services/wallets.dart';
|
||||
|
@ -14,9 +13,7 @@ import 'package:stackwallet/utilities/prefs.dart';
|
|||
LocaleService,
|
||||
ThemeService,
|
||||
Prefs,
|
||||
], customMocks: [
|
||||
MockSpec<CoinServiceAPI>(returnNullOnMissingStub: true),
|
||||
])
|
||||
], customMocks: [])
|
||||
void main() {
|
||||
// testWidgets("Send to valid address", (widgetTester) async {
|
||||
// final mockWallets = MockWallets();
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -1,183 +0,0 @@
|
|||
import 'package:stackwallet/models/balance.dart';
|
||||
import 'package:stackwallet/models/isar/models/blockchain_data/transaction.dart';
|
||||
import 'package:stackwallet/models/isar/models/blockchain_data/utxo.dart';
|
||||
import 'package:stackwallet/models/paymint/fee_object_model.dart';
|
||||
import 'package:stackwallet/services/coins/coin_service.dart';
|
||||
import 'package:stackwallet/utilities/amount/amount.dart';
|
||||
import 'package:stackwallet/utilities/enums/coin_enum.dart';
|
||||
|
||||
class FakeCoinServiceAPI extends CoinServiceAPI {
|
||||
@override
|
||||
// TODO: implement currentReceivingAddress
|
||||
Future<String> get currentReceivingAddress => throw UnimplementedError();
|
||||
|
||||
@override
|
||||
Future<void> exit() {
|
||||
// TODO: implement exit
|
||||
throw UnimplementedError();
|
||||
}
|
||||
|
||||
@override
|
||||
// TODO: implement maxFee
|
||||
Future<int> get maxFee => throw UnimplementedError();
|
||||
|
||||
@override
|
||||
// TODO: implement mnemonic
|
||||
Future<List<String>> get mnemonic => throw UnimplementedError();
|
||||
|
||||
@override
|
||||
Future<void> refresh() {
|
||||
// TODO: implement refresh
|
||||
throw UnimplementedError();
|
||||
}
|
||||
|
||||
@override
|
||||
bool validateAddress(String address) {
|
||||
// TODO: implement validateAddress
|
||||
throw UnimplementedError();
|
||||
}
|
||||
|
||||
@override
|
||||
// TODO: implement walletId
|
||||
String get walletId => throw UnimplementedError();
|
||||
|
||||
@override
|
||||
// TODO: implement walletName
|
||||
String get walletName => throw UnimplementedError();
|
||||
|
||||
@override
|
||||
Future<void> fullRescan(
|
||||
int maxUnusedAddressGap, int maxNumberOfIndexesToCheck) {
|
||||
// TODO: implement fullRescan
|
||||
throw UnimplementedError();
|
||||
}
|
||||
|
||||
@override
|
||||
bool get isFavorite => throw UnimplementedError();
|
||||
|
||||
@override
|
||||
set isFavorite(bool isFavorite) => throw UnimplementedError();
|
||||
|
||||
@override
|
||||
late bool shouldAutoSync;
|
||||
|
||||
@override
|
||||
// TODO: implement coin
|
||||
Coin get coin => throw UnimplementedError();
|
||||
|
||||
@override
|
||||
Future<String> confirmSend({required Map<String, dynamic> txData}) {
|
||||
// TODO: implement confirmSend
|
||||
throw UnimplementedError();
|
||||
}
|
||||
|
||||
@override
|
||||
Future<Amount> estimateFeeFor(Amount amount, int feeRate) {
|
||||
// TODO: implement estimateFeeFor
|
||||
throw UnimplementedError();
|
||||
}
|
||||
|
||||
@override
|
||||
// TODO: implement hasCalledExit
|
||||
bool get hasCalledExit => throw UnimplementedError();
|
||||
|
||||
@override
|
||||
Future<void> initializeExisting() {
|
||||
// TODO: implement initializeExisting
|
||||
throw UnimplementedError();
|
||||
}
|
||||
|
||||
@override
|
||||
Future<void> initializeNew(
|
||||
({String mnemonicPassphrase, int wordCount})? data,
|
||||
) {
|
||||
// TODO: implement initializeNew
|
||||
throw UnimplementedError();
|
||||
}
|
||||
|
||||
@override
|
||||
// TODO: implement isConnected
|
||||
bool get isConnected => throw UnimplementedError();
|
||||
|
||||
@override
|
||||
// TODO: implement isRefreshing
|
||||
bool get isRefreshing => throw UnimplementedError();
|
||||
|
||||
@override
|
||||
Future<Map<String, dynamic>> prepareSend(
|
||||
{required String address,
|
||||
required Amount amount,
|
||||
Map<String, dynamic>? args}) {
|
||||
// TODO: implement prepareSend
|
||||
throw UnimplementedError();
|
||||
}
|
||||
|
||||
@override
|
||||
Future<void> updateNode(bool shouldRefresh) {
|
||||
// TODO: implement updateNode
|
||||
throw UnimplementedError();
|
||||
}
|
||||
|
||||
@override
|
||||
set walletName(String newName) {
|
||||
// TODO: implement walletName
|
||||
}
|
||||
|
||||
@override
|
||||
// TODO: implement fees
|
||||
Future<FeeObject> get fees => throw UnimplementedError();
|
||||
|
||||
@override
|
||||
Future<void> recoverFromMnemonic({
|
||||
required String mnemonic,
|
||||
String? mnemonicPassphrase,
|
||||
required int maxUnusedAddressGap,
|
||||
required int maxNumberOfIndexesToCheck,
|
||||
required int height,
|
||||
}) {
|
||||
// TODO: implement recoverFromMnemonic
|
||||
throw UnimplementedError();
|
||||
}
|
||||
|
||||
@override
|
||||
Future<bool> testNetworkConnection() {
|
||||
// TODO: implement testNetworkConnection
|
||||
throw UnimplementedError();
|
||||
}
|
||||
|
||||
@override
|
||||
Future<bool> generateNewAddress() {
|
||||
// TODO: implement generateNewAddress
|
||||
throw UnimplementedError();
|
||||
}
|
||||
|
||||
@override
|
||||
Future<void> updateSentCachedTxData(Map<String, dynamic> txData) {
|
||||
// TODO: implement updateSentCachedTxData
|
||||
throw UnimplementedError();
|
||||
}
|
||||
|
||||
@override
|
||||
// TODO: implement balance
|
||||
Balance get balance => throw UnimplementedError();
|
||||
|
||||
@override
|
||||
// TODO: implement storedChainHeight
|
||||
int get storedChainHeight => throw UnimplementedError();
|
||||
|
||||
@override
|
||||
// TODO: implement transactions
|
||||
Future<List<Transaction>> get transactions => throw UnimplementedError();
|
||||
|
||||
@override
|
||||
// TODO: implement utxos
|
||||
Future<List<UTXO>> get utxos => throw UnimplementedError();
|
||||
|
||||
@override
|
||||
// TODO: implement mnemonicPassphrase
|
||||
Future<String?> get mnemonicPassphrase => throw UnimplementedError();
|
||||
|
||||
@override
|
||||
// TODO: implement mnemonicString
|
||||
Future<String?> get mnemonicString => throw UnimplementedError();
|
||||
}
|
|
@ -1,6 +1,5 @@
|
|||
import 'package:decimal/decimal.dart';
|
||||
import 'package:mockito/annotations.dart';
|
||||
import 'package:stackwallet/services/coins/coin_service.dart';
|
||||
import 'package:stackwallet/services/locale_service.dart';
|
||||
import 'package:stackwallet/services/node_service.dart';
|
||||
import 'package:stackwallet/services/wallets.dart';
|
||||
|
@ -24,7 +23,6 @@ Amount _a(int i) => Amount.fromDecimal(
|
|||
LocaleService
|
||||
], customMocks: [
|
||||
MockSpec<NodeService>(returnNullOnMissingStub: true),
|
||||
MockSpec<CoinServiceAPI>(returnNullOnMissingStub: true),
|
||||
])
|
||||
void main() {
|
||||
// testWidgets("Test wallet info row displays correctly", (widgetTester) async {
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -1,5 +1,4 @@
|
|||
import 'package:mockito/annotations.dart';
|
||||
import 'package:stackwallet/services/coins/coin_service.dart';
|
||||
import 'package:stackwallet/services/wallets.dart';
|
||||
import 'package:stackwallet/services/wallets_service.dart';
|
||||
import 'package:stackwallet/themes/theme_service.dart';
|
||||
|
@ -8,9 +7,7 @@ import 'package:stackwallet/themes/theme_service.dart';
|
|||
Wallets,
|
||||
WalletsService,
|
||||
ThemeService,
|
||||
], customMocks: [
|
||||
MockSpec<CoinServiceAPI>(returnNullOnMissingStub: true)
|
||||
])
|
||||
], customMocks: [])
|
||||
void main() {
|
||||
// testWidgets('Test table view row', (widgetTester) async {
|
||||
// widgetTester.binding.window.physicalSizeTestValue = const Size(2500, 1800);
|
||||
|
|
|
@ -3,30 +3,25 @@
|
|||
// Do not manually edit this file.
|
||||
|
||||
// ignore_for_file: no_leading_underscores_for_library_prefixes
|
||||
import 'dart:async' as _i11;
|
||||
import 'dart:typed_data' as _i20;
|
||||
import 'dart:ui' as _i17;
|
||||
import 'dart:async' as _i8;
|
||||
import 'dart:typed_data' as _i17;
|
||||
import 'dart:ui' as _i14;
|
||||
|
||||
import 'package:mockito/mockito.dart' as _i1;
|
||||
import 'package:stackwallet/db/isar/main_db.dart' as _i3;
|
||||
import 'package:stackwallet/models/balance.dart' as _i8;
|
||||
import 'package:stackwallet/models/isar/models/isar_models.dart' as _i22;
|
||||
import 'package:stackwallet/models/isar/stack_theme.dart' as _i19;
|
||||
import 'package:stackwallet/models/paymint/fee_object_model.dart' as _i7;
|
||||
import 'package:stackwallet/models/isar/stack_theme.dart' as _i16;
|
||||
import 'package:stackwallet/networking/http.dart' as _i6;
|
||||
import 'package:stackwallet/services/coins/coin_service.dart' as _i21;
|
||||
import 'package:stackwallet/services/node_service.dart' as _i2;
|
||||
import 'package:stackwallet/services/wallets.dart' as _i10;
|
||||
import 'package:stackwallet/services/wallets_service.dart' as _i15;
|
||||
import 'package:stackwallet/themes/theme_service.dart' as _i18;
|
||||
import 'package:stackwallet/utilities/amount/amount.dart' as _i9;
|
||||
import 'package:stackwallet/utilities/enums/coin_enum.dart' as _i16;
|
||||
import 'package:stackwallet/services/wallets.dart' as _i7;
|
||||
import 'package:stackwallet/services/wallets_service.dart' as _i12;
|
||||
import 'package:stackwallet/themes/theme_service.dart' as _i15;
|
||||
import 'package:stackwallet/utilities/enums/coin_enum.dart' as _i13;
|
||||
import 'package:stackwallet/utilities/flutter_secure_storage_interface.dart'
|
||||
as _i13;
|
||||
import 'package:stackwallet/utilities/prefs.dart' as _i14;
|
||||
as _i10;
|
||||
import 'package:stackwallet/utilities/prefs.dart' as _i11;
|
||||
import 'package:stackwallet/wallets/crypto_currency/crypto_currency.dart'
|
||||
as _i4;
|
||||
import 'package:stackwallet/wallets/isar/models/wallet_info.dart' as _i12;
|
||||
import 'package:stackwallet/wallets/isar/models/wallet_info.dart' as _i9;
|
||||
import 'package:stackwallet/wallets/wallet/wallet.dart' as _i5;
|
||||
|
||||
// ignore_for_file: type=lint
|
||||
|
@ -81,40 +76,10 @@ class _FakeHTTP_3 extends _i1.SmartFake implements _i6.HTTP {
|
|||
);
|
||||
}
|
||||
|
||||
class _FakeFeeObject_4 extends _i1.SmartFake implements _i7.FeeObject {
|
||||
_FakeFeeObject_4(
|
||||
Object parent,
|
||||
Invocation parentInvocation,
|
||||
) : super(
|
||||
parent,
|
||||
parentInvocation,
|
||||
);
|
||||
}
|
||||
|
||||
class _FakeBalance_5 extends _i1.SmartFake implements _i8.Balance {
|
||||
_FakeBalance_5(
|
||||
Object parent,
|
||||
Invocation parentInvocation,
|
||||
) : super(
|
||||
parent,
|
||||
parentInvocation,
|
||||
);
|
||||
}
|
||||
|
||||
class _FakeAmount_6 extends _i1.SmartFake implements _i9.Amount {
|
||||
_FakeAmount_6(
|
||||
Object parent,
|
||||
Invocation parentInvocation,
|
||||
) : super(
|
||||
parent,
|
||||
parentInvocation,
|
||||
);
|
||||
}
|
||||
|
||||
/// A class which mocks [Wallets].
|
||||
///
|
||||
/// See the documentation for Mockito's code generation for more information.
|
||||
class MockWallets extends _i1.Mock implements _i10.Wallets {
|
||||
class MockWallets extends _i1.Mock implements _i7.Wallets {
|
||||
MockWallets() {
|
||||
_i1.throwOnMissingStub(this);
|
||||
}
|
||||
|
@ -180,9 +145,9 @@ class MockWallets extends _i1.Mock implements _i10.Wallets {
|
|||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
_i11.Future<void> deleteWallet(
|
||||
_i12.WalletInfo? info,
|
||||
_i13.SecureStorageInterface? secureStorage,
|
||||
_i8.Future<void> deleteWallet(
|
||||
_i9.WalletInfo? info,
|
||||
_i10.SecureStorageInterface? secureStorage,
|
||||
) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
|
@ -192,12 +157,12 @@ class MockWallets extends _i1.Mock implements _i10.Wallets {
|
|||
secureStorage,
|
||||
],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> load(
|
||||
_i14.Prefs? prefs,
|
||||
_i8.Future<void> load(
|
||||
_i11.Prefs? prefs,
|
||||
_i3.MainDB? mainDB,
|
||||
) =>
|
||||
(super.noSuchMethod(
|
||||
|
@ -208,12 +173,12 @@ class MockWallets extends _i1.Mock implements _i10.Wallets {
|
|||
mainDB,
|
||||
],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> loadAfterStackRestore(
|
||||
_i14.Prefs? prefs,
|
||||
_i8.Future<void> loadAfterStackRestore(
|
||||
_i11.Prefs? prefs,
|
||||
List<_i5.Wallet<_i4.CryptoCurrency>>? wallets,
|
||||
) =>
|
||||
(super.noSuchMethod(
|
||||
|
@ -224,33 +189,33 @@ class MockWallets extends _i1.Mock implements _i10.Wallets {
|
|||
wallets,
|
||||
],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
}
|
||||
|
||||
/// A class which mocks [WalletsService].
|
||||
///
|
||||
/// See the documentation for Mockito's code generation for more information.
|
||||
class MockWalletsService extends _i1.Mock implements _i15.WalletsService {
|
||||
class MockWalletsService extends _i1.Mock implements _i12.WalletsService {
|
||||
MockWalletsService() {
|
||||
_i1.throwOnMissingStub(this);
|
||||
}
|
||||
|
||||
@override
|
||||
_i11.Future<Map<String, _i15.WalletInfo>> get walletNames =>
|
||||
_i8.Future<Map<String, _i12.WalletInfo>> get walletNames =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.getter(#walletNames),
|
||||
returnValue: _i11.Future<Map<String, _i15.WalletInfo>>.value(
|
||||
<String, _i15.WalletInfo>{}),
|
||||
) as _i11.Future<Map<String, _i15.WalletInfo>>);
|
||||
returnValue: _i8.Future<Map<String, _i12.WalletInfo>>.value(
|
||||
<String, _i12.WalletInfo>{}),
|
||||
) as _i8.Future<Map<String, _i12.WalletInfo>>);
|
||||
@override
|
||||
bool get hasListeners => (super.noSuchMethod(
|
||||
Invocation.getter(#hasListeners),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
_i11.Future<bool> renameWallet({
|
||||
_i8.Future<bool> renameWallet({
|
||||
required String? from,
|
||||
required String? to,
|
||||
required bool? shouldNotifyListeners,
|
||||
|
@ -265,21 +230,21 @@ class MockWalletsService extends _i1.Mock implements _i15.WalletsService {
|
|||
#shouldNotifyListeners: shouldNotifyListeners,
|
||||
},
|
||||
),
|
||||
returnValue: _i11.Future<bool>.value(false),
|
||||
) as _i11.Future<bool>);
|
||||
returnValue: _i8.Future<bool>.value(false),
|
||||
) as _i8.Future<bool>);
|
||||
@override
|
||||
Map<String, _i15.WalletInfo> fetchWalletsData() => (super.noSuchMethod(
|
||||
Map<String, _i12.WalletInfo> fetchWalletsData() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#fetchWalletsData,
|
||||
[],
|
||||
),
|
||||
returnValue: <String, _i15.WalletInfo>{},
|
||||
) as Map<String, _i15.WalletInfo>);
|
||||
returnValue: <String, _i12.WalletInfo>{},
|
||||
) as Map<String, _i12.WalletInfo>);
|
||||
@override
|
||||
_i11.Future<void> addExistingStackWallet({
|
||||
_i8.Future<void> addExistingStackWallet({
|
||||
required String? name,
|
||||
required String? walletId,
|
||||
required _i16.Coin? coin,
|
||||
required _i13.Coin? coin,
|
||||
required bool? shouldNotifyListeners,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
|
@ -293,13 +258,13 @@ class MockWalletsService extends _i1.Mock implements _i15.WalletsService {
|
|||
#shouldNotifyListeners: shouldNotifyListeners,
|
||||
},
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<String?> addNewWallet({
|
||||
_i8.Future<String?> addNewWallet({
|
||||
required String? name,
|
||||
required _i16.Coin? coin,
|
||||
required _i13.Coin? coin,
|
||||
required bool? shouldNotifyListeners,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
|
@ -312,46 +277,46 @@ class MockWalletsService extends _i1.Mock implements _i15.WalletsService {
|
|||
#shouldNotifyListeners: shouldNotifyListeners,
|
||||
},
|
||||
),
|
||||
returnValue: _i11.Future<String?>.value(),
|
||||
) as _i11.Future<String?>);
|
||||
returnValue: _i8.Future<String?>.value(),
|
||||
) as _i8.Future<String?>);
|
||||
@override
|
||||
_i11.Future<List<String>> getFavoriteWalletIds() => (super.noSuchMethod(
|
||||
_i8.Future<List<String>> getFavoriteWalletIds() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getFavoriteWalletIds,
|
||||
[],
|
||||
),
|
||||
returnValue: _i11.Future<List<String>>.value(<String>[]),
|
||||
) as _i11.Future<List<String>>);
|
||||
returnValue: _i8.Future<List<String>>.value(<String>[]),
|
||||
) as _i8.Future<List<String>>);
|
||||
@override
|
||||
_i11.Future<void> saveFavoriteWalletIds(List<String>? walletIds) =>
|
||||
_i8.Future<void> saveFavoriteWalletIds(List<String>? walletIds) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#saveFavoriteWalletIds,
|
||||
[walletIds],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> addFavorite(String? walletId) => (super.noSuchMethod(
|
||||
_i8.Future<void> addFavorite(String? walletId) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#addFavorite,
|
||||
[walletId],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> removeFavorite(String? walletId) => (super.noSuchMethod(
|
||||
_i8.Future<void> removeFavorite(String? walletId) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#removeFavorite,
|
||||
[walletId],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> moveFavorite({
|
||||
_i8.Future<void> moveFavorite({
|
||||
required int? fromIndex,
|
||||
required int? toIndex,
|
||||
}) =>
|
||||
|
@ -364,48 +329,48 @@ class MockWalletsService extends _i1.Mock implements _i15.WalletsService {
|
|||
#toIndex: toIndex,
|
||||
},
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<bool> checkForDuplicate(String? name) => (super.noSuchMethod(
|
||||
_i8.Future<bool> checkForDuplicate(String? name) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#checkForDuplicate,
|
||||
[name],
|
||||
),
|
||||
returnValue: _i11.Future<bool>.value(false),
|
||||
) as _i11.Future<bool>);
|
||||
returnValue: _i8.Future<bool>.value(false),
|
||||
) as _i8.Future<bool>);
|
||||
@override
|
||||
_i11.Future<String?> getWalletId(String? walletName) => (super.noSuchMethod(
|
||||
_i8.Future<String?> getWalletId(String? walletName) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getWalletId,
|
||||
[walletName],
|
||||
),
|
||||
returnValue: _i11.Future<String?>.value(),
|
||||
) as _i11.Future<String?>);
|
||||
returnValue: _i8.Future<String?>.value(),
|
||||
) as _i8.Future<String?>);
|
||||
@override
|
||||
_i11.Future<bool> isMnemonicVerified({required String? walletId}) =>
|
||||
_i8.Future<bool> isMnemonicVerified({required String? walletId}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#isMnemonicVerified,
|
||||
[],
|
||||
{#walletId: walletId},
|
||||
),
|
||||
returnValue: _i11.Future<bool>.value(false),
|
||||
) as _i11.Future<bool>);
|
||||
returnValue: _i8.Future<bool>.value(false),
|
||||
) as _i8.Future<bool>);
|
||||
@override
|
||||
_i11.Future<void> setMnemonicVerified({required String? walletId}) =>
|
||||
_i8.Future<void> setMnemonicVerified({required String? walletId}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#setMnemonicVerified,
|
||||
[],
|
||||
{#walletId: walletId},
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<int> deleteWallet(
|
||||
_i8.Future<int> deleteWallet(
|
||||
String? name,
|
||||
bool? shouldNotifyListeners,
|
||||
) =>
|
||||
|
@ -417,20 +382,20 @@ class MockWalletsService extends _i1.Mock implements _i15.WalletsService {
|
|||
shouldNotifyListeners,
|
||||
],
|
||||
),
|
||||
returnValue: _i11.Future<int>.value(0),
|
||||
) as _i11.Future<int>);
|
||||
returnValue: _i8.Future<int>.value(0),
|
||||
) as _i8.Future<int>);
|
||||
@override
|
||||
_i11.Future<void> refreshWallets(bool? shouldNotifyListeners) =>
|
||||
_i8.Future<void> refreshWallets(bool? shouldNotifyListeners) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#refreshWallets,
|
||||
[shouldNotifyListeners],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
void addListener(_i17.VoidCallback? listener) => super.noSuchMethod(
|
||||
void addListener(_i14.VoidCallback? listener) => super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#addListener,
|
||||
[listener],
|
||||
|
@ -438,7 +403,7 @@ class MockWalletsService extends _i1.Mock implements _i15.WalletsService {
|
|||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
void removeListener(_i17.VoidCallback? listener) => super.noSuchMethod(
|
||||
void removeListener(_i14.VoidCallback? listener) => super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#removeListener,
|
||||
[listener],
|
||||
|
@ -466,7 +431,7 @@ class MockWalletsService extends _i1.Mock implements _i15.WalletsService {
|
|||
/// A class which mocks [ThemeService].
|
||||
///
|
||||
/// See the documentation for Mockito's code generation for more information.
|
||||
class MockThemeService extends _i1.Mock implements _i18.ThemeService {
|
||||
class MockThemeService extends _i1.Mock implements _i15.ThemeService {
|
||||
MockThemeService() {
|
||||
_i1.throwOnMissingStub(this);
|
||||
}
|
||||
|
@ -496,10 +461,10 @@ class MockThemeService extends _i1.Mock implements _i18.ThemeService {
|
|||
),
|
||||
) as _i3.MainDB);
|
||||
@override
|
||||
List<_i19.StackTheme> get installedThemes => (super.noSuchMethod(
|
||||
List<_i16.StackTheme> get installedThemes => (super.noSuchMethod(
|
||||
Invocation.getter(#installedThemes),
|
||||
returnValue: <_i19.StackTheme>[],
|
||||
) as List<_i19.StackTheme>);
|
||||
returnValue: <_i16.StackTheme>[],
|
||||
) as List<_i16.StackTheme>);
|
||||
@override
|
||||
void init(_i3.MainDB? db) => super.noSuchMethod(
|
||||
Invocation.method(
|
||||
|
@ -509,380 +474,71 @@ class MockThemeService extends _i1.Mock implements _i18.ThemeService {
|
|||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
_i11.Future<void> install({required _i20.Uint8List? themeArchiveData}) =>
|
||||
_i8.Future<void> install({required _i17.Uint8List? themeArchiveData}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#install,
|
||||
[],
|
||||
{#themeArchiveData: themeArchiveData},
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> remove({required String? themeId}) => (super.noSuchMethod(
|
||||
_i8.Future<void> remove({required String? themeId}) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#remove,
|
||||
[],
|
||||
{#themeId: themeId},
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> checkDefaultThemesOnStartup() => (super.noSuchMethod(
|
||||
_i8.Future<void> checkDefaultThemesOnStartup() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#checkDefaultThemesOnStartup,
|
||||
[],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<bool> verifyInstalled({required String? themeId}) =>
|
||||
_i8.Future<bool> verifyInstalled({required String? themeId}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#verifyInstalled,
|
||||
[],
|
||||
{#themeId: themeId},
|
||||
),
|
||||
returnValue: _i11.Future<bool>.value(false),
|
||||
) as _i11.Future<bool>);
|
||||
returnValue: _i8.Future<bool>.value(false),
|
||||
) as _i8.Future<bool>);
|
||||
@override
|
||||
_i11.Future<List<_i18.StackThemeMetaData>> fetchThemes() =>
|
||||
_i8.Future<List<_i15.StackThemeMetaData>> fetchThemes() =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#fetchThemes,
|
||||
[],
|
||||
),
|
||||
returnValue: _i11.Future<List<_i18.StackThemeMetaData>>.value(
|
||||
<_i18.StackThemeMetaData>[]),
|
||||
) as _i11.Future<List<_i18.StackThemeMetaData>>);
|
||||
returnValue: _i8.Future<List<_i15.StackThemeMetaData>>.value(
|
||||
<_i15.StackThemeMetaData>[]),
|
||||
) as _i8.Future<List<_i15.StackThemeMetaData>>);
|
||||
@override
|
||||
_i11.Future<_i20.Uint8List> fetchTheme(
|
||||
{required _i18.StackThemeMetaData? themeMetaData}) =>
|
||||
_i8.Future<_i17.Uint8List> fetchTheme(
|
||||
{required _i15.StackThemeMetaData? themeMetaData}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#fetchTheme,
|
||||
[],
|
||||
{#themeMetaData: themeMetaData},
|
||||
),
|
||||
returnValue: _i11.Future<_i20.Uint8List>.value(_i20.Uint8List(0)),
|
||||
) as _i11.Future<_i20.Uint8List>);
|
||||
returnValue: _i8.Future<_i17.Uint8List>.value(_i17.Uint8List(0)),
|
||||
) as _i8.Future<_i17.Uint8List>);
|
||||
@override
|
||||
_i19.StackTheme? getTheme({required String? themeId}) =>
|
||||
_i16.StackTheme? getTheme({required String? themeId}) =>
|
||||
(super.noSuchMethod(Invocation.method(
|
||||
#getTheme,
|
||||
[],
|
||||
{#themeId: themeId},
|
||||
)) as _i19.StackTheme?);
|
||||
}
|
||||
|
||||
/// A class which mocks [CoinServiceAPI].
|
||||
///
|
||||
/// See the documentation for Mockito's code generation for more information.
|
||||
class MockCoinServiceAPI extends _i1.Mock implements _i21.CoinServiceAPI {
|
||||
@override
|
||||
set onIsActiveWalletChanged(void Function(bool)? _onIsActiveWalletChanged) =>
|
||||
super.noSuchMethod(
|
||||
Invocation.setter(
|
||||
#onIsActiveWalletChanged,
|
||||
_onIsActiveWalletChanged,
|
||||
),
|
||||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
_i16.Coin get coin => (super.noSuchMethod(
|
||||
Invocation.getter(#coin),
|
||||
returnValue: _i16.Coin.bitcoin,
|
||||
) as _i16.Coin);
|
||||
@override
|
||||
bool get isRefreshing => (super.noSuchMethod(
|
||||
Invocation.getter(#isRefreshing),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
bool get shouldAutoSync => (super.noSuchMethod(
|
||||
Invocation.getter(#shouldAutoSync),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
set shouldAutoSync(bool? shouldAutoSync) => super.noSuchMethod(
|
||||
Invocation.setter(
|
||||
#shouldAutoSync,
|
||||
shouldAutoSync,
|
||||
),
|
||||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
bool get isFavorite => (super.noSuchMethod(
|
||||
Invocation.getter(#isFavorite),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
set isFavorite(bool? markFavorite) => super.noSuchMethod(
|
||||
Invocation.setter(
|
||||
#isFavorite,
|
||||
markFavorite,
|
||||
),
|
||||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
_i11.Future<_i7.FeeObject> get fees => (super.noSuchMethod(
|
||||
Invocation.getter(#fees),
|
||||
returnValue: _i11.Future<_i7.FeeObject>.value(_FakeFeeObject_4(
|
||||
this,
|
||||
Invocation.getter(#fees),
|
||||
)),
|
||||
) as _i11.Future<_i7.FeeObject>);
|
||||
@override
|
||||
_i11.Future<int> get maxFee => (super.noSuchMethod(
|
||||
Invocation.getter(#maxFee),
|
||||
returnValue: _i11.Future<int>.value(0),
|
||||
) as _i11.Future<int>);
|
||||
@override
|
||||
_i11.Future<String> get currentReceivingAddress => (super.noSuchMethod(
|
||||
Invocation.getter(#currentReceivingAddress),
|
||||
returnValue: _i11.Future<String>.value(''),
|
||||
) as _i11.Future<String>);
|
||||
@override
|
||||
_i8.Balance get balance => (super.noSuchMethod(
|
||||
Invocation.getter(#balance),
|
||||
returnValue: _FakeBalance_5(
|
||||
this,
|
||||
Invocation.getter(#balance),
|
||||
),
|
||||
) as _i8.Balance);
|
||||
@override
|
||||
_i11.Future<List<_i22.Transaction>> get transactions => (super.noSuchMethod(
|
||||
Invocation.getter(#transactions),
|
||||
returnValue:
|
||||
_i11.Future<List<_i22.Transaction>>.value(<_i22.Transaction>[]),
|
||||
) as _i11.Future<List<_i22.Transaction>>);
|
||||
@override
|
||||
_i11.Future<List<_i22.UTXO>> get utxos => (super.noSuchMethod(
|
||||
Invocation.getter(#utxos),
|
||||
returnValue: _i11.Future<List<_i22.UTXO>>.value(<_i22.UTXO>[]),
|
||||
) as _i11.Future<List<_i22.UTXO>>);
|
||||
@override
|
||||
set walletName(String? newName) => super.noSuchMethod(
|
||||
Invocation.setter(
|
||||
#walletName,
|
||||
newName,
|
||||
),
|
||||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
String get walletName => (super.noSuchMethod(
|
||||
Invocation.getter(#walletName),
|
||||
returnValue: '',
|
||||
) as String);
|
||||
@override
|
||||
String get walletId => (super.noSuchMethod(
|
||||
Invocation.getter(#walletId),
|
||||
returnValue: '',
|
||||
) as String);
|
||||
@override
|
||||
_i11.Future<List<String>> get mnemonic => (super.noSuchMethod(
|
||||
Invocation.getter(#mnemonic),
|
||||
returnValue: _i11.Future<List<String>>.value(<String>[]),
|
||||
) as _i11.Future<List<String>>);
|
||||
@override
|
||||
_i11.Future<String?> get mnemonicString => (super.noSuchMethod(
|
||||
Invocation.getter(#mnemonicString),
|
||||
returnValue: _i11.Future<String?>.value(),
|
||||
) as _i11.Future<String?>);
|
||||
@override
|
||||
_i11.Future<String?> get mnemonicPassphrase => (super.noSuchMethod(
|
||||
Invocation.getter(#mnemonicPassphrase),
|
||||
returnValue: _i11.Future<String?>.value(),
|
||||
) as _i11.Future<String?>);
|
||||
@override
|
||||
bool get hasCalledExit => (super.noSuchMethod(
|
||||
Invocation.getter(#hasCalledExit),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
bool get isConnected => (super.noSuchMethod(
|
||||
Invocation.getter(#isConnected),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
int get storedChainHeight => (super.noSuchMethod(
|
||||
Invocation.getter(#storedChainHeight),
|
||||
returnValue: 0,
|
||||
) as int);
|
||||
@override
|
||||
_i11.Future<Map<String, dynamic>> prepareSend({
|
||||
required String? address,
|
||||
required _i9.Amount? amount,
|
||||
Map<String, dynamic>? args,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#prepareSend,
|
||||
[],
|
||||
{
|
||||
#address: address,
|
||||
#amount: amount,
|
||||
#args: args,
|
||||
},
|
||||
),
|
||||
returnValue:
|
||||
_i11.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i11.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i11.Future<String> confirmSend({required Map<String, dynamic>? txData}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#confirmSend,
|
||||
[],
|
||||
{#txData: txData},
|
||||
),
|
||||
returnValue: _i11.Future<String>.value(''),
|
||||
) as _i11.Future<String>);
|
||||
@override
|
||||
_i11.Future<void> refresh() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#refresh,
|
||||
[],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> updateNode(bool? shouldRefresh) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#updateNode,
|
||||
[shouldRefresh],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
@override
|
||||
bool validateAddress(String? address) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#validateAddress,
|
||||
[address],
|
||||
),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
_i11.Future<bool> testNetworkConnection() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#testNetworkConnection,
|
||||
[],
|
||||
),
|
||||
returnValue: _i11.Future<bool>.value(false),
|
||||
) as _i11.Future<bool>);
|
||||
@override
|
||||
_i11.Future<void> recoverFromMnemonic({
|
||||
required String? mnemonic,
|
||||
String? mnemonicPassphrase,
|
||||
required int? maxUnusedAddressGap,
|
||||
required int? maxNumberOfIndexesToCheck,
|
||||
required int? height,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#recoverFromMnemonic,
|
||||
[],
|
||||
{
|
||||
#mnemonic: mnemonic,
|
||||
#mnemonicPassphrase: mnemonicPassphrase,
|
||||
#maxUnusedAddressGap: maxUnusedAddressGap,
|
||||
#maxNumberOfIndexesToCheck: maxNumberOfIndexesToCheck,
|
||||
#height: height,
|
||||
},
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> initializeNew(
|
||||
({String mnemonicPassphrase, int wordCount})? data) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#initializeNew,
|
||||
[data],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> initializeExisting() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#initializeExisting,
|
||||
[],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> exit() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#exit,
|
||||
[],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> fullRescan(
|
||||
int? maxUnusedAddressGap,
|
||||
int? maxNumberOfIndexesToCheck,
|
||||
) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#fullRescan,
|
||||
[
|
||||
maxUnusedAddressGap,
|
||||
maxNumberOfIndexesToCheck,
|
||||
],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
@override
|
||||
_i11.Future<_i9.Amount> estimateFeeFor(
|
||||
_i9.Amount? amount,
|
||||
int? feeRate,
|
||||
) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#estimateFeeFor,
|
||||
[
|
||||
amount,
|
||||
feeRate,
|
||||
],
|
||||
),
|
||||
returnValue: _i11.Future<_i9.Amount>.value(_FakeAmount_6(
|
||||
this,
|
||||
Invocation.method(
|
||||
#estimateFeeFor,
|
||||
[
|
||||
amount,
|
||||
feeRate,
|
||||
],
|
||||
),
|
||||
)),
|
||||
) as _i11.Future<_i9.Amount>);
|
||||
@override
|
||||
_i11.Future<bool> generateNewAddress() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#generateNewAddress,
|
||||
[],
|
||||
),
|
||||
returnValue: _i11.Future<bool>.value(false),
|
||||
) as _i11.Future<bool>);
|
||||
@override
|
||||
_i11.Future<void> updateSentCachedTxData(Map<String, dynamic>? txData) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#updateSentCachedTxData,
|
||||
[txData],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
)) as _i16.StackTheme?);
|
||||
}
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
import 'package:mockito/annotations.dart';
|
||||
import 'package:stackwallet/db/isar/main_db.dart';
|
||||
import 'package:stackwallet/models/isar/stack_theme.dart';
|
||||
import 'package:stackwallet/services/coins/coin_service.dart';
|
||||
import 'package:stackwallet/services/locale_service.dart';
|
||||
import 'package:stackwallet/services/price_service.dart';
|
||||
import 'package:stackwallet/services/wallets.dart';
|
||||
|
@ -10,7 +9,6 @@ import 'package:stackwallet/utilities/prefs.dart';
|
|||
|
||||
@GenerateMocks([
|
||||
Wallets,
|
||||
CoinServiceAPI,
|
||||
LocaleService,
|
||||
Prefs,
|
||||
PriceService,
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -1,5 +1,4 @@
|
|||
import 'package:mockito/annotations.dart';
|
||||
import 'package:stackwallet/services/coins/coin_service.dart';
|
||||
import 'package:stackwallet/services/node_service.dart';
|
||||
import 'package:stackwallet/services/wallets.dart';
|
||||
import 'package:stackwallet/services/wallets_service.dart';
|
||||
|
@ -9,7 +8,6 @@ import 'package:stackwallet/services/wallets_service.dart';
|
|||
WalletsService,
|
||||
], customMocks: [
|
||||
MockSpec<NodeService>(returnNullOnMissingStub: true),
|
||||
MockSpec<CoinServiceAPI>(returnNullOnMissingStub: true),
|
||||
// MockSpec<WalletsService>(returnNullOnMissingStub: true),
|
||||
])
|
||||
void main() {
|
||||
|
|
|
@ -3,27 +3,22 @@
|
|||
// Do not manually edit this file.
|
||||
|
||||
// ignore_for_file: no_leading_underscores_for_library_prefixes
|
||||
import 'dart:async' as _i11;
|
||||
import 'dart:ui' as _i16;
|
||||
import 'dart:async' as _i8;
|
||||
import 'dart:ui' as _i13;
|
||||
|
||||
import 'package:mockito/mockito.dart' as _i1;
|
||||
import 'package:stackwallet/db/isar/main_db.dart' as _i3;
|
||||
import 'package:stackwallet/models/balance.dart' as _i8;
|
||||
import 'package:stackwallet/models/isar/models/isar_models.dart' as _i19;
|
||||
import 'package:stackwallet/models/node_model.dart' as _i17;
|
||||
import 'package:stackwallet/models/paymint/fee_object_model.dart' as _i7;
|
||||
import 'package:stackwallet/services/coins/coin_service.dart' as _i18;
|
||||
import 'package:stackwallet/models/node_model.dart' as _i14;
|
||||
import 'package:stackwallet/services/node_service.dart' as _i2;
|
||||
import 'package:stackwallet/services/wallets.dart' as _i10;
|
||||
import 'package:stackwallet/services/wallets_service.dart' as _i14;
|
||||
import 'package:stackwallet/utilities/amount/amount.dart' as _i9;
|
||||
import 'package:stackwallet/utilities/enums/coin_enum.dart' as _i15;
|
||||
import 'package:stackwallet/services/wallets.dart' as _i7;
|
||||
import 'package:stackwallet/services/wallets_service.dart' as _i11;
|
||||
import 'package:stackwallet/utilities/enums/coin_enum.dart' as _i12;
|
||||
import 'package:stackwallet/utilities/flutter_secure_storage_interface.dart'
|
||||
as _i6;
|
||||
import 'package:stackwallet/utilities/prefs.dart' as _i13;
|
||||
import 'package:stackwallet/utilities/prefs.dart' as _i10;
|
||||
import 'package:stackwallet/wallets/crypto_currency/crypto_currency.dart'
|
||||
as _i4;
|
||||
import 'package:stackwallet/wallets/isar/models/wallet_info.dart' as _i12;
|
||||
import 'package:stackwallet/wallets/isar/models/wallet_info.dart' as _i9;
|
||||
import 'package:stackwallet/wallets/wallet/wallet.dart' as _i5;
|
||||
|
||||
// ignore_for_file: type=lint
|
||||
|
@ -79,40 +74,10 @@ class _FakeSecureStorageInterface_3 extends _i1.SmartFake
|
|||
);
|
||||
}
|
||||
|
||||
class _FakeFeeObject_4 extends _i1.SmartFake implements _i7.FeeObject {
|
||||
_FakeFeeObject_4(
|
||||
Object parent,
|
||||
Invocation parentInvocation,
|
||||
) : super(
|
||||
parent,
|
||||
parentInvocation,
|
||||
);
|
||||
}
|
||||
|
||||
class _FakeBalance_5 extends _i1.SmartFake implements _i8.Balance {
|
||||
_FakeBalance_5(
|
||||
Object parent,
|
||||
Invocation parentInvocation,
|
||||
) : super(
|
||||
parent,
|
||||
parentInvocation,
|
||||
);
|
||||
}
|
||||
|
||||
class _FakeAmount_6 extends _i1.SmartFake implements _i9.Amount {
|
||||
_FakeAmount_6(
|
||||
Object parent,
|
||||
Invocation parentInvocation,
|
||||
) : super(
|
||||
parent,
|
||||
parentInvocation,
|
||||
);
|
||||
}
|
||||
|
||||
/// A class which mocks [Wallets].
|
||||
///
|
||||
/// See the documentation for Mockito's code generation for more information.
|
||||
class MockWallets extends _i1.Mock implements _i10.Wallets {
|
||||
class MockWallets extends _i1.Mock implements _i7.Wallets {
|
||||
MockWallets() {
|
||||
_i1.throwOnMissingStub(this);
|
||||
}
|
||||
|
@ -178,8 +143,8 @@ class MockWallets extends _i1.Mock implements _i10.Wallets {
|
|||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
_i11.Future<void> deleteWallet(
|
||||
_i12.WalletInfo? info,
|
||||
_i8.Future<void> deleteWallet(
|
||||
_i9.WalletInfo? info,
|
||||
_i6.SecureStorageInterface? secureStorage,
|
||||
) =>
|
||||
(super.noSuchMethod(
|
||||
|
@ -190,12 +155,12 @@ class MockWallets extends _i1.Mock implements _i10.Wallets {
|
|||
secureStorage,
|
||||
],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> load(
|
||||
_i13.Prefs? prefs,
|
||||
_i8.Future<void> load(
|
||||
_i10.Prefs? prefs,
|
||||
_i3.MainDB? mainDB,
|
||||
) =>
|
||||
(super.noSuchMethod(
|
||||
|
@ -206,12 +171,12 @@ class MockWallets extends _i1.Mock implements _i10.Wallets {
|
|||
mainDB,
|
||||
],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> loadAfterStackRestore(
|
||||
_i13.Prefs? prefs,
|
||||
_i8.Future<void> loadAfterStackRestore(
|
||||
_i10.Prefs? prefs,
|
||||
List<_i5.Wallet<_i4.CryptoCurrency>>? wallets,
|
||||
) =>
|
||||
(super.noSuchMethod(
|
||||
|
@ -222,33 +187,33 @@ class MockWallets extends _i1.Mock implements _i10.Wallets {
|
|||
wallets,
|
||||
],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
}
|
||||
|
||||
/// A class which mocks [WalletsService].
|
||||
///
|
||||
/// See the documentation for Mockito's code generation for more information.
|
||||
class MockWalletsService extends _i1.Mock implements _i14.WalletsService {
|
||||
class MockWalletsService extends _i1.Mock implements _i11.WalletsService {
|
||||
MockWalletsService() {
|
||||
_i1.throwOnMissingStub(this);
|
||||
}
|
||||
|
||||
@override
|
||||
_i11.Future<Map<String, _i14.WalletInfo>> get walletNames =>
|
||||
_i8.Future<Map<String, _i11.WalletInfo>> get walletNames =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.getter(#walletNames),
|
||||
returnValue: _i11.Future<Map<String, _i14.WalletInfo>>.value(
|
||||
<String, _i14.WalletInfo>{}),
|
||||
) as _i11.Future<Map<String, _i14.WalletInfo>>);
|
||||
returnValue: _i8.Future<Map<String, _i11.WalletInfo>>.value(
|
||||
<String, _i11.WalletInfo>{}),
|
||||
) as _i8.Future<Map<String, _i11.WalletInfo>>);
|
||||
@override
|
||||
bool get hasListeners => (super.noSuchMethod(
|
||||
Invocation.getter(#hasListeners),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
_i11.Future<bool> renameWallet({
|
||||
_i8.Future<bool> renameWallet({
|
||||
required String? from,
|
||||
required String? to,
|
||||
required bool? shouldNotifyListeners,
|
||||
|
@ -263,21 +228,21 @@ class MockWalletsService extends _i1.Mock implements _i14.WalletsService {
|
|||
#shouldNotifyListeners: shouldNotifyListeners,
|
||||
},
|
||||
),
|
||||
returnValue: _i11.Future<bool>.value(false),
|
||||
) as _i11.Future<bool>);
|
||||
returnValue: _i8.Future<bool>.value(false),
|
||||
) as _i8.Future<bool>);
|
||||
@override
|
||||
Map<String, _i14.WalletInfo> fetchWalletsData() => (super.noSuchMethod(
|
||||
Map<String, _i11.WalletInfo> fetchWalletsData() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#fetchWalletsData,
|
||||
[],
|
||||
),
|
||||
returnValue: <String, _i14.WalletInfo>{},
|
||||
) as Map<String, _i14.WalletInfo>);
|
||||
returnValue: <String, _i11.WalletInfo>{},
|
||||
) as Map<String, _i11.WalletInfo>);
|
||||
@override
|
||||
_i11.Future<void> addExistingStackWallet({
|
||||
_i8.Future<void> addExistingStackWallet({
|
||||
required String? name,
|
||||
required String? walletId,
|
||||
required _i15.Coin? coin,
|
||||
required _i12.Coin? coin,
|
||||
required bool? shouldNotifyListeners,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
|
@ -291,13 +256,13 @@ class MockWalletsService extends _i1.Mock implements _i14.WalletsService {
|
|||
#shouldNotifyListeners: shouldNotifyListeners,
|
||||
},
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<String?> addNewWallet({
|
||||
_i8.Future<String?> addNewWallet({
|
||||
required String? name,
|
||||
required _i15.Coin? coin,
|
||||
required _i12.Coin? coin,
|
||||
required bool? shouldNotifyListeners,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
|
@ -310,46 +275,46 @@ class MockWalletsService extends _i1.Mock implements _i14.WalletsService {
|
|||
#shouldNotifyListeners: shouldNotifyListeners,
|
||||
},
|
||||
),
|
||||
returnValue: _i11.Future<String?>.value(),
|
||||
) as _i11.Future<String?>);
|
||||
returnValue: _i8.Future<String?>.value(),
|
||||
) as _i8.Future<String?>);
|
||||
@override
|
||||
_i11.Future<List<String>> getFavoriteWalletIds() => (super.noSuchMethod(
|
||||
_i8.Future<List<String>> getFavoriteWalletIds() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getFavoriteWalletIds,
|
||||
[],
|
||||
),
|
||||
returnValue: _i11.Future<List<String>>.value(<String>[]),
|
||||
) as _i11.Future<List<String>>);
|
||||
returnValue: _i8.Future<List<String>>.value(<String>[]),
|
||||
) as _i8.Future<List<String>>);
|
||||
@override
|
||||
_i11.Future<void> saveFavoriteWalletIds(List<String>? walletIds) =>
|
||||
_i8.Future<void> saveFavoriteWalletIds(List<String>? walletIds) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#saveFavoriteWalletIds,
|
||||
[walletIds],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> addFavorite(String? walletId) => (super.noSuchMethod(
|
||||
_i8.Future<void> addFavorite(String? walletId) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#addFavorite,
|
||||
[walletId],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> removeFavorite(String? walletId) => (super.noSuchMethod(
|
||||
_i8.Future<void> removeFavorite(String? walletId) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#removeFavorite,
|
||||
[walletId],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> moveFavorite({
|
||||
_i8.Future<void> moveFavorite({
|
||||
required int? fromIndex,
|
||||
required int? toIndex,
|
||||
}) =>
|
||||
|
@ -362,48 +327,48 @@ class MockWalletsService extends _i1.Mock implements _i14.WalletsService {
|
|||
#toIndex: toIndex,
|
||||
},
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<bool> checkForDuplicate(String? name) => (super.noSuchMethod(
|
||||
_i8.Future<bool> checkForDuplicate(String? name) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#checkForDuplicate,
|
||||
[name],
|
||||
),
|
||||
returnValue: _i11.Future<bool>.value(false),
|
||||
) as _i11.Future<bool>);
|
||||
returnValue: _i8.Future<bool>.value(false),
|
||||
) as _i8.Future<bool>);
|
||||
@override
|
||||
_i11.Future<String?> getWalletId(String? walletName) => (super.noSuchMethod(
|
||||
_i8.Future<String?> getWalletId(String? walletName) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getWalletId,
|
||||
[walletName],
|
||||
),
|
||||
returnValue: _i11.Future<String?>.value(),
|
||||
) as _i11.Future<String?>);
|
||||
returnValue: _i8.Future<String?>.value(),
|
||||
) as _i8.Future<String?>);
|
||||
@override
|
||||
_i11.Future<bool> isMnemonicVerified({required String? walletId}) =>
|
||||
_i8.Future<bool> isMnemonicVerified({required String? walletId}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#isMnemonicVerified,
|
||||
[],
|
||||
{#walletId: walletId},
|
||||
),
|
||||
returnValue: _i11.Future<bool>.value(false),
|
||||
) as _i11.Future<bool>);
|
||||
returnValue: _i8.Future<bool>.value(false),
|
||||
) as _i8.Future<bool>);
|
||||
@override
|
||||
_i11.Future<void> setMnemonicVerified({required String? walletId}) =>
|
||||
_i8.Future<void> setMnemonicVerified({required String? walletId}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#setMnemonicVerified,
|
||||
[],
|
||||
{#walletId: walletId},
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<int> deleteWallet(
|
||||
_i8.Future<int> deleteWallet(
|
||||
String? name,
|
||||
bool? shouldNotifyListeners,
|
||||
) =>
|
||||
|
@ -415,20 +380,20 @@ class MockWalletsService extends _i1.Mock implements _i14.WalletsService {
|
|||
shouldNotifyListeners,
|
||||
],
|
||||
),
|
||||
returnValue: _i11.Future<int>.value(0),
|
||||
) as _i11.Future<int>);
|
||||
returnValue: _i8.Future<int>.value(0),
|
||||
) as _i8.Future<int>);
|
||||
@override
|
||||
_i11.Future<void> refreshWallets(bool? shouldNotifyListeners) =>
|
||||
_i8.Future<void> refreshWallets(bool? shouldNotifyListeners) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#refreshWallets,
|
||||
[shouldNotifyListeners],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
void addListener(_i16.VoidCallback? listener) => super.noSuchMethod(
|
||||
void addListener(_i13.VoidCallback? listener) => super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#addListener,
|
||||
[listener],
|
||||
|
@ -436,7 +401,7 @@ class MockWalletsService extends _i1.Mock implements _i14.WalletsService {
|
|||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
void removeListener(_i16.VoidCallback? listener) => super.noSuchMethod(
|
||||
void removeListener(_i13.VoidCallback? listener) => super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#removeListener,
|
||||
[listener],
|
||||
|
@ -474,33 +439,33 @@ class MockNodeService extends _i1.Mock implements _i2.NodeService {
|
|||
),
|
||||
) as _i6.SecureStorageInterface);
|
||||
@override
|
||||
List<_i17.NodeModel> get primaryNodes => (super.noSuchMethod(
|
||||
List<_i14.NodeModel> get primaryNodes => (super.noSuchMethod(
|
||||
Invocation.getter(#primaryNodes),
|
||||
returnValue: <_i17.NodeModel>[],
|
||||
) as List<_i17.NodeModel>);
|
||||
returnValue: <_i14.NodeModel>[],
|
||||
) as List<_i14.NodeModel>);
|
||||
@override
|
||||
List<_i17.NodeModel> get nodes => (super.noSuchMethod(
|
||||
List<_i14.NodeModel> get nodes => (super.noSuchMethod(
|
||||
Invocation.getter(#nodes),
|
||||
returnValue: <_i17.NodeModel>[],
|
||||
) as List<_i17.NodeModel>);
|
||||
returnValue: <_i14.NodeModel>[],
|
||||
) as List<_i14.NodeModel>);
|
||||
@override
|
||||
bool get hasListeners => (super.noSuchMethod(
|
||||
Invocation.getter(#hasListeners),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
_i11.Future<void> updateDefaults() => (super.noSuchMethod(
|
||||
_i8.Future<void> updateDefaults() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#updateDefaults,
|
||||
[],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> setPrimaryNodeFor({
|
||||
required _i15.Coin? coin,
|
||||
required _i17.NodeModel? node,
|
||||
_i8.Future<void> setPrimaryNodeFor({
|
||||
required _i12.Coin? coin,
|
||||
required _i14.NodeModel? node,
|
||||
bool? shouldNotifyListeners = false,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
|
@ -513,44 +478,44 @@ class MockNodeService extends _i1.Mock implements _i2.NodeService {
|
|||
#shouldNotifyListeners: shouldNotifyListeners,
|
||||
},
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i17.NodeModel? getPrimaryNodeFor({required _i15.Coin? coin}) =>
|
||||
_i14.NodeModel? getPrimaryNodeFor({required _i12.Coin? coin}) =>
|
||||
(super.noSuchMethod(Invocation.method(
|
||||
#getPrimaryNodeFor,
|
||||
[],
|
||||
{#coin: coin},
|
||||
)) as _i17.NodeModel?);
|
||||
)) as _i14.NodeModel?);
|
||||
@override
|
||||
List<_i17.NodeModel> getNodesFor(_i15.Coin? coin) => (super.noSuchMethod(
|
||||
List<_i14.NodeModel> getNodesFor(_i12.Coin? coin) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getNodesFor,
|
||||
[coin],
|
||||
),
|
||||
returnValue: <_i17.NodeModel>[],
|
||||
) as List<_i17.NodeModel>);
|
||||
returnValue: <_i14.NodeModel>[],
|
||||
) as List<_i14.NodeModel>);
|
||||
@override
|
||||
_i17.NodeModel? getNodeById({required String? id}) =>
|
||||
_i14.NodeModel? getNodeById({required String? id}) =>
|
||||
(super.noSuchMethod(Invocation.method(
|
||||
#getNodeById,
|
||||
[],
|
||||
{#id: id},
|
||||
)) as _i17.NodeModel?);
|
||||
)) as _i14.NodeModel?);
|
||||
@override
|
||||
List<_i17.NodeModel> failoverNodesFor({required _i15.Coin? coin}) =>
|
||||
List<_i14.NodeModel> failoverNodesFor({required _i12.Coin? coin}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#failoverNodesFor,
|
||||
[],
|
||||
{#coin: coin},
|
||||
),
|
||||
returnValue: <_i17.NodeModel>[],
|
||||
) as List<_i17.NodeModel>);
|
||||
returnValue: <_i14.NodeModel>[],
|
||||
) as List<_i14.NodeModel>);
|
||||
@override
|
||||
_i11.Future<void> add(
|
||||
_i17.NodeModel? node,
|
||||
_i8.Future<void> add(
|
||||
_i14.NodeModel? node,
|
||||
String? password,
|
||||
bool? shouldNotifyListeners,
|
||||
) =>
|
||||
|
@ -563,11 +528,11 @@ class MockNodeService extends _i1.Mock implements _i2.NodeService {
|
|||
shouldNotifyListeners,
|
||||
],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> delete(
|
||||
_i8.Future<void> delete(
|
||||
String? id,
|
||||
bool? shouldNotifyListeners,
|
||||
) =>
|
||||
|
@ -579,11 +544,11 @@ class MockNodeService extends _i1.Mock implements _i2.NodeService {
|
|||
shouldNotifyListeners,
|
||||
],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> setEnabledState(
|
||||
_i8.Future<void> setEnabledState(
|
||||
String? id,
|
||||
bool? enabled,
|
||||
bool? shouldNotifyListeners,
|
||||
|
@ -597,12 +562,12 @@ class MockNodeService extends _i1.Mock implements _i2.NodeService {
|
|||
shouldNotifyListeners,
|
||||
],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> edit(
|
||||
_i17.NodeModel? editedNode,
|
||||
_i8.Future<void> edit(
|
||||
_i14.NodeModel? editedNode,
|
||||
String? password,
|
||||
bool? shouldNotifyListeners,
|
||||
) =>
|
||||
|
@ -615,20 +580,20 @@ class MockNodeService extends _i1.Mock implements _i2.NodeService {
|
|||
shouldNotifyListeners,
|
||||
],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> updateCommunityNodes() => (super.noSuchMethod(
|
||||
_i8.Future<void> updateCommunityNodes() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#updateCommunityNodes,
|
||||
[],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
returnValue: _i8.Future<void>.value(),
|
||||
returnValueForMissingStub: _i8.Future<void>.value(),
|
||||
) as _i8.Future<void>);
|
||||
@override
|
||||
void addListener(_i16.VoidCallback? listener) => super.noSuchMethod(
|
||||
void addListener(_i13.VoidCallback? listener) => super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#addListener,
|
||||
[listener],
|
||||
|
@ -636,7 +601,7 @@ class MockNodeService extends _i1.Mock implements _i2.NodeService {
|
|||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
void removeListener(_i16.VoidCallback? listener) => super.noSuchMethod(
|
||||
void removeListener(_i13.VoidCallback? listener) => super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#removeListener,
|
||||
[listener],
|
||||
|
@ -660,312 +625,3 @@ class MockNodeService extends _i1.Mock implements _i2.NodeService {
|
|||
returnValueForMissingStub: null,
|
||||
);
|
||||
}
|
||||
|
||||
/// A class which mocks [CoinServiceAPI].
|
||||
///
|
||||
/// See the documentation for Mockito's code generation for more information.
|
||||
class MockCoinServiceAPI extends _i1.Mock implements _i18.CoinServiceAPI {
|
||||
@override
|
||||
set onIsActiveWalletChanged(void Function(bool)? _onIsActiveWalletChanged) =>
|
||||
super.noSuchMethod(
|
||||
Invocation.setter(
|
||||
#onIsActiveWalletChanged,
|
||||
_onIsActiveWalletChanged,
|
||||
),
|
||||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
_i15.Coin get coin => (super.noSuchMethod(
|
||||
Invocation.getter(#coin),
|
||||
returnValue: _i15.Coin.bitcoin,
|
||||
) as _i15.Coin);
|
||||
@override
|
||||
bool get isRefreshing => (super.noSuchMethod(
|
||||
Invocation.getter(#isRefreshing),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
bool get shouldAutoSync => (super.noSuchMethod(
|
||||
Invocation.getter(#shouldAutoSync),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
set shouldAutoSync(bool? shouldAutoSync) => super.noSuchMethod(
|
||||
Invocation.setter(
|
||||
#shouldAutoSync,
|
||||
shouldAutoSync,
|
||||
),
|
||||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
bool get isFavorite => (super.noSuchMethod(
|
||||
Invocation.getter(#isFavorite),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
set isFavorite(bool? markFavorite) => super.noSuchMethod(
|
||||
Invocation.setter(
|
||||
#isFavorite,
|
||||
markFavorite,
|
||||
),
|
||||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
_i11.Future<_i7.FeeObject> get fees => (super.noSuchMethod(
|
||||
Invocation.getter(#fees),
|
||||
returnValue: _i11.Future<_i7.FeeObject>.value(_FakeFeeObject_4(
|
||||
this,
|
||||
Invocation.getter(#fees),
|
||||
)),
|
||||
) as _i11.Future<_i7.FeeObject>);
|
||||
@override
|
||||
_i11.Future<int> get maxFee => (super.noSuchMethod(
|
||||
Invocation.getter(#maxFee),
|
||||
returnValue: _i11.Future<int>.value(0),
|
||||
) as _i11.Future<int>);
|
||||
@override
|
||||
_i11.Future<String> get currentReceivingAddress => (super.noSuchMethod(
|
||||
Invocation.getter(#currentReceivingAddress),
|
||||
returnValue: _i11.Future<String>.value(''),
|
||||
) as _i11.Future<String>);
|
||||
@override
|
||||
_i8.Balance get balance => (super.noSuchMethod(
|
||||
Invocation.getter(#balance),
|
||||
returnValue: _FakeBalance_5(
|
||||
this,
|
||||
Invocation.getter(#balance),
|
||||
),
|
||||
) as _i8.Balance);
|
||||
@override
|
||||
_i11.Future<List<_i19.Transaction>> get transactions => (super.noSuchMethod(
|
||||
Invocation.getter(#transactions),
|
||||
returnValue:
|
||||
_i11.Future<List<_i19.Transaction>>.value(<_i19.Transaction>[]),
|
||||
) as _i11.Future<List<_i19.Transaction>>);
|
||||
@override
|
||||
_i11.Future<List<_i19.UTXO>> get utxos => (super.noSuchMethod(
|
||||
Invocation.getter(#utxos),
|
||||
returnValue: _i11.Future<List<_i19.UTXO>>.value(<_i19.UTXO>[]),
|
||||
) as _i11.Future<List<_i19.UTXO>>);
|
||||
@override
|
||||
set walletName(String? newName) => super.noSuchMethod(
|
||||
Invocation.setter(
|
||||
#walletName,
|
||||
newName,
|
||||
),
|
||||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
String get walletName => (super.noSuchMethod(
|
||||
Invocation.getter(#walletName),
|
||||
returnValue: '',
|
||||
) as String);
|
||||
@override
|
||||
String get walletId => (super.noSuchMethod(
|
||||
Invocation.getter(#walletId),
|
||||
returnValue: '',
|
||||
) as String);
|
||||
@override
|
||||
_i11.Future<List<String>> get mnemonic => (super.noSuchMethod(
|
||||
Invocation.getter(#mnemonic),
|
||||
returnValue: _i11.Future<List<String>>.value(<String>[]),
|
||||
) as _i11.Future<List<String>>);
|
||||
@override
|
||||
_i11.Future<String?> get mnemonicString => (super.noSuchMethod(
|
||||
Invocation.getter(#mnemonicString),
|
||||
returnValue: _i11.Future<String?>.value(),
|
||||
) as _i11.Future<String?>);
|
||||
@override
|
||||
_i11.Future<String?> get mnemonicPassphrase => (super.noSuchMethod(
|
||||
Invocation.getter(#mnemonicPassphrase),
|
||||
returnValue: _i11.Future<String?>.value(),
|
||||
) as _i11.Future<String?>);
|
||||
@override
|
||||
bool get hasCalledExit => (super.noSuchMethod(
|
||||
Invocation.getter(#hasCalledExit),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
bool get isConnected => (super.noSuchMethod(
|
||||
Invocation.getter(#isConnected),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
int get storedChainHeight => (super.noSuchMethod(
|
||||
Invocation.getter(#storedChainHeight),
|
||||
returnValue: 0,
|
||||
) as int);
|
||||
@override
|
||||
_i11.Future<Map<String, dynamic>> prepareSend({
|
||||
required String? address,
|
||||
required _i9.Amount? amount,
|
||||
Map<String, dynamic>? args,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#prepareSend,
|
||||
[],
|
||||
{
|
||||
#address: address,
|
||||
#amount: amount,
|
||||
#args: args,
|
||||
},
|
||||
),
|
||||
returnValue:
|
||||
_i11.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i11.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i11.Future<String> confirmSend({required Map<String, dynamic>? txData}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#confirmSend,
|
||||
[],
|
||||
{#txData: txData},
|
||||
),
|
||||
returnValue: _i11.Future<String>.value(''),
|
||||
) as _i11.Future<String>);
|
||||
@override
|
||||
_i11.Future<void> refresh() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#refresh,
|
||||
[],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> updateNode(bool? shouldRefresh) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#updateNode,
|
||||
[shouldRefresh],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
@override
|
||||
bool validateAddress(String? address) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#validateAddress,
|
||||
[address],
|
||||
),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
_i11.Future<bool> testNetworkConnection() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#testNetworkConnection,
|
||||
[],
|
||||
),
|
||||
returnValue: _i11.Future<bool>.value(false),
|
||||
) as _i11.Future<bool>);
|
||||
@override
|
||||
_i11.Future<void> recoverFromMnemonic({
|
||||
required String? mnemonic,
|
||||
String? mnemonicPassphrase,
|
||||
required int? maxUnusedAddressGap,
|
||||
required int? maxNumberOfIndexesToCheck,
|
||||
required int? height,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#recoverFromMnemonic,
|
||||
[],
|
||||
{
|
||||
#mnemonic: mnemonic,
|
||||
#mnemonicPassphrase: mnemonicPassphrase,
|
||||
#maxUnusedAddressGap: maxUnusedAddressGap,
|
||||
#maxNumberOfIndexesToCheck: maxNumberOfIndexesToCheck,
|
||||
#height: height,
|
||||
},
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> initializeNew(
|
||||
({String mnemonicPassphrase, int wordCount})? data) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#initializeNew,
|
||||
[data],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> initializeExisting() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#initializeExisting,
|
||||
[],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> exit() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#exit,
|
||||
[],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
@override
|
||||
_i11.Future<void> fullRescan(
|
||||
int? maxUnusedAddressGap,
|
||||
int? maxNumberOfIndexesToCheck,
|
||||
) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#fullRescan,
|
||||
[
|
||||
maxUnusedAddressGap,
|
||||
maxNumberOfIndexesToCheck,
|
||||
],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
@override
|
||||
_i11.Future<_i9.Amount> estimateFeeFor(
|
||||
_i9.Amount? amount,
|
||||
int? feeRate,
|
||||
) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#estimateFeeFor,
|
||||
[
|
||||
amount,
|
||||
feeRate,
|
||||
],
|
||||
),
|
||||
returnValue: _i11.Future<_i9.Amount>.value(_FakeAmount_6(
|
||||
this,
|
||||
Invocation.method(
|
||||
#estimateFeeFor,
|
||||
[
|
||||
amount,
|
||||
feeRate,
|
||||
],
|
||||
),
|
||||
)),
|
||||
) as _i11.Future<_i9.Amount>);
|
||||
@override
|
||||
_i11.Future<bool> generateNewAddress() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#generateNewAddress,
|
||||
[],
|
||||
),
|
||||
returnValue: _i11.Future<bool>.value(false),
|
||||
) as _i11.Future<bool>);
|
||||
@override
|
||||
_i11.Future<void> updateSentCachedTxData(Map<String, dynamic>? txData) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#updateSentCachedTxData,
|
||||
[txData],
|
||||
),
|
||||
returnValue: _i11.Future<void>.value(),
|
||||
returnValueForMissingStub: _i11.Future<void>.value(),
|
||||
) as _i11.Future<void>);
|
||||
}
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
import 'package:mockito/annotations.dart';
|
||||
import 'package:stackwallet/services/coins/coin_service.dart';
|
||||
import 'package:stackwallet/services/node_service.dart';
|
||||
import 'package:stackwallet/services/wallets.dart';
|
||||
import 'package:stackwallet/services/wallets_service.dart';
|
||||
|
@ -11,7 +10,6 @@ import 'package:stackwallet/themes/theme_service.dart';
|
|||
ThemeService,
|
||||
], customMocks: [
|
||||
MockSpec<NodeService>(returnNullOnMissingStub: true),
|
||||
MockSpec<CoinServiceAPI>(returnNullOnMissingStub: true),
|
||||
// MockSpec<WalletsService>(returnNullOnMissingStub: true),
|
||||
])
|
||||
void main() {
|
||||
|
|
|
@ -3,31 +3,26 @@
|
|||
// Do not manually edit this file.
|
||||
|
||||
// ignore_for_file: no_leading_underscores_for_library_prefixes
|
||||
import 'dart:async' as _i12;
|
||||
import 'dart:typed_data' as _i20;
|
||||
import 'dart:ui' as _i17;
|
||||
import 'dart:async' as _i9;
|
||||
import 'dart:typed_data' as _i17;
|
||||
import 'dart:ui' as _i14;
|
||||
|
||||
import 'package:mockito/mockito.dart' as _i1;
|
||||
import 'package:stackwallet/db/isar/main_db.dart' as _i3;
|
||||
import 'package:stackwallet/models/balance.dart' as _i9;
|
||||
import 'package:stackwallet/models/isar/models/isar_models.dart' as _i23;
|
||||
import 'package:stackwallet/models/isar/stack_theme.dart' as _i19;
|
||||
import 'package:stackwallet/models/node_model.dart' as _i21;
|
||||
import 'package:stackwallet/models/paymint/fee_object_model.dart' as _i8;
|
||||
import 'package:stackwallet/models/isar/stack_theme.dart' as _i16;
|
||||
import 'package:stackwallet/models/node_model.dart' as _i18;
|
||||
import 'package:stackwallet/networking/http.dart' as _i6;
|
||||
import 'package:stackwallet/services/coins/coin_service.dart' as _i22;
|
||||
import 'package:stackwallet/services/node_service.dart' as _i2;
|
||||
import 'package:stackwallet/services/wallets.dart' as _i11;
|
||||
import 'package:stackwallet/services/wallets_service.dart' as _i15;
|
||||
import 'package:stackwallet/themes/theme_service.dart' as _i18;
|
||||
import 'package:stackwallet/utilities/amount/amount.dart' as _i10;
|
||||
import 'package:stackwallet/utilities/enums/coin_enum.dart' as _i16;
|
||||
import 'package:stackwallet/services/wallets.dart' as _i8;
|
||||
import 'package:stackwallet/services/wallets_service.dart' as _i12;
|
||||
import 'package:stackwallet/themes/theme_service.dart' as _i15;
|
||||
import 'package:stackwallet/utilities/enums/coin_enum.dart' as _i13;
|
||||
import 'package:stackwallet/utilities/flutter_secure_storage_interface.dart'
|
||||
as _i7;
|
||||
import 'package:stackwallet/utilities/prefs.dart' as _i14;
|
||||
import 'package:stackwallet/utilities/prefs.dart' as _i11;
|
||||
import 'package:stackwallet/wallets/crypto_currency/crypto_currency.dart'
|
||||
as _i4;
|
||||
import 'package:stackwallet/wallets/isar/models/wallet_info.dart' as _i13;
|
||||
import 'package:stackwallet/wallets/isar/models/wallet_info.dart' as _i10;
|
||||
import 'package:stackwallet/wallets/wallet/wallet.dart' as _i5;
|
||||
|
||||
// ignore_for_file: type=lint
|
||||
|
@ -93,40 +88,10 @@ class _FakeSecureStorageInterface_4 extends _i1.SmartFake
|
|||
);
|
||||
}
|
||||
|
||||
class _FakeFeeObject_5 extends _i1.SmartFake implements _i8.FeeObject {
|
||||
_FakeFeeObject_5(
|
||||
Object parent,
|
||||
Invocation parentInvocation,
|
||||
) : super(
|
||||
parent,
|
||||
parentInvocation,
|
||||
);
|
||||
}
|
||||
|
||||
class _FakeBalance_6 extends _i1.SmartFake implements _i9.Balance {
|
||||
_FakeBalance_6(
|
||||
Object parent,
|
||||
Invocation parentInvocation,
|
||||
) : super(
|
||||
parent,
|
||||
parentInvocation,
|
||||
);
|
||||
}
|
||||
|
||||
class _FakeAmount_7 extends _i1.SmartFake implements _i10.Amount {
|
||||
_FakeAmount_7(
|
||||
Object parent,
|
||||
Invocation parentInvocation,
|
||||
) : super(
|
||||
parent,
|
||||
parentInvocation,
|
||||
);
|
||||
}
|
||||
|
||||
/// A class which mocks [Wallets].
|
||||
///
|
||||
/// See the documentation for Mockito's code generation for more information.
|
||||
class MockWallets extends _i1.Mock implements _i11.Wallets {
|
||||
class MockWallets extends _i1.Mock implements _i8.Wallets {
|
||||
MockWallets() {
|
||||
_i1.throwOnMissingStub(this);
|
||||
}
|
||||
|
@ -192,8 +157,8 @@ class MockWallets extends _i1.Mock implements _i11.Wallets {
|
|||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
_i12.Future<void> deleteWallet(
|
||||
_i13.WalletInfo? info,
|
||||
_i9.Future<void> deleteWallet(
|
||||
_i10.WalletInfo? info,
|
||||
_i7.SecureStorageInterface? secureStorage,
|
||||
) =>
|
||||
(super.noSuchMethod(
|
||||
|
@ -204,12 +169,12 @@ class MockWallets extends _i1.Mock implements _i11.Wallets {
|
|||
secureStorage,
|
||||
],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
_i12.Future<void> load(
|
||||
_i14.Prefs? prefs,
|
||||
_i9.Future<void> load(
|
||||
_i11.Prefs? prefs,
|
||||
_i3.MainDB? mainDB,
|
||||
) =>
|
||||
(super.noSuchMethod(
|
||||
|
@ -220,12 +185,12 @@ class MockWallets extends _i1.Mock implements _i11.Wallets {
|
|||
mainDB,
|
||||
],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
_i12.Future<void> loadAfterStackRestore(
|
||||
_i14.Prefs? prefs,
|
||||
_i9.Future<void> loadAfterStackRestore(
|
||||
_i11.Prefs? prefs,
|
||||
List<_i5.Wallet<_i4.CryptoCurrency>>? wallets,
|
||||
) =>
|
||||
(super.noSuchMethod(
|
||||
|
@ -236,33 +201,33 @@ class MockWallets extends _i1.Mock implements _i11.Wallets {
|
|||
wallets,
|
||||
],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
}
|
||||
|
||||
/// A class which mocks [WalletsService].
|
||||
///
|
||||
/// See the documentation for Mockito's code generation for more information.
|
||||
class MockWalletsService extends _i1.Mock implements _i15.WalletsService {
|
||||
class MockWalletsService extends _i1.Mock implements _i12.WalletsService {
|
||||
MockWalletsService() {
|
||||
_i1.throwOnMissingStub(this);
|
||||
}
|
||||
|
||||
@override
|
||||
_i12.Future<Map<String, _i15.WalletInfo>> get walletNames =>
|
||||
_i9.Future<Map<String, _i12.WalletInfo>> get walletNames =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.getter(#walletNames),
|
||||
returnValue: _i12.Future<Map<String, _i15.WalletInfo>>.value(
|
||||
<String, _i15.WalletInfo>{}),
|
||||
) as _i12.Future<Map<String, _i15.WalletInfo>>);
|
||||
returnValue: _i9.Future<Map<String, _i12.WalletInfo>>.value(
|
||||
<String, _i12.WalletInfo>{}),
|
||||
) as _i9.Future<Map<String, _i12.WalletInfo>>);
|
||||
@override
|
||||
bool get hasListeners => (super.noSuchMethod(
|
||||
Invocation.getter(#hasListeners),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
_i12.Future<bool> renameWallet({
|
||||
_i9.Future<bool> renameWallet({
|
||||
required String? from,
|
||||
required String? to,
|
||||
required bool? shouldNotifyListeners,
|
||||
|
@ -277,21 +242,21 @@ class MockWalletsService extends _i1.Mock implements _i15.WalletsService {
|
|||
#shouldNotifyListeners: shouldNotifyListeners,
|
||||
},
|
||||
),
|
||||
returnValue: _i12.Future<bool>.value(false),
|
||||
) as _i12.Future<bool>);
|
||||
returnValue: _i9.Future<bool>.value(false),
|
||||
) as _i9.Future<bool>);
|
||||
@override
|
||||
Map<String, _i15.WalletInfo> fetchWalletsData() => (super.noSuchMethod(
|
||||
Map<String, _i12.WalletInfo> fetchWalletsData() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#fetchWalletsData,
|
||||
[],
|
||||
),
|
||||
returnValue: <String, _i15.WalletInfo>{},
|
||||
) as Map<String, _i15.WalletInfo>);
|
||||
returnValue: <String, _i12.WalletInfo>{},
|
||||
) as Map<String, _i12.WalletInfo>);
|
||||
@override
|
||||
_i12.Future<void> addExistingStackWallet({
|
||||
_i9.Future<void> addExistingStackWallet({
|
||||
required String? name,
|
||||
required String? walletId,
|
||||
required _i16.Coin? coin,
|
||||
required _i13.Coin? coin,
|
||||
required bool? shouldNotifyListeners,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
|
@ -305,13 +270,13 @@ class MockWalletsService extends _i1.Mock implements _i15.WalletsService {
|
|||
#shouldNotifyListeners: shouldNotifyListeners,
|
||||
},
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
_i12.Future<String?> addNewWallet({
|
||||
_i9.Future<String?> addNewWallet({
|
||||
required String? name,
|
||||
required _i16.Coin? coin,
|
||||
required _i13.Coin? coin,
|
||||
required bool? shouldNotifyListeners,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
|
@ -324,46 +289,46 @@ class MockWalletsService extends _i1.Mock implements _i15.WalletsService {
|
|||
#shouldNotifyListeners: shouldNotifyListeners,
|
||||
},
|
||||
),
|
||||
returnValue: _i12.Future<String?>.value(),
|
||||
) as _i12.Future<String?>);
|
||||
returnValue: _i9.Future<String?>.value(),
|
||||
) as _i9.Future<String?>);
|
||||
@override
|
||||
_i12.Future<List<String>> getFavoriteWalletIds() => (super.noSuchMethod(
|
||||
_i9.Future<List<String>> getFavoriteWalletIds() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getFavoriteWalletIds,
|
||||
[],
|
||||
),
|
||||
returnValue: _i12.Future<List<String>>.value(<String>[]),
|
||||
) as _i12.Future<List<String>>);
|
||||
returnValue: _i9.Future<List<String>>.value(<String>[]),
|
||||
) as _i9.Future<List<String>>);
|
||||
@override
|
||||
_i12.Future<void> saveFavoriteWalletIds(List<String>? walletIds) =>
|
||||
_i9.Future<void> saveFavoriteWalletIds(List<String>? walletIds) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#saveFavoriteWalletIds,
|
||||
[walletIds],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
_i12.Future<void> addFavorite(String? walletId) => (super.noSuchMethod(
|
||||
_i9.Future<void> addFavorite(String? walletId) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#addFavorite,
|
||||
[walletId],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
_i12.Future<void> removeFavorite(String? walletId) => (super.noSuchMethod(
|
||||
_i9.Future<void> removeFavorite(String? walletId) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#removeFavorite,
|
||||
[walletId],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
_i12.Future<void> moveFavorite({
|
||||
_i9.Future<void> moveFavorite({
|
||||
required int? fromIndex,
|
||||
required int? toIndex,
|
||||
}) =>
|
||||
|
@ -376,48 +341,48 @@ class MockWalletsService extends _i1.Mock implements _i15.WalletsService {
|
|||
#toIndex: toIndex,
|
||||
},
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
_i12.Future<bool> checkForDuplicate(String? name) => (super.noSuchMethod(
|
||||
_i9.Future<bool> checkForDuplicate(String? name) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#checkForDuplicate,
|
||||
[name],
|
||||
),
|
||||
returnValue: _i12.Future<bool>.value(false),
|
||||
) as _i12.Future<bool>);
|
||||
returnValue: _i9.Future<bool>.value(false),
|
||||
) as _i9.Future<bool>);
|
||||
@override
|
||||
_i12.Future<String?> getWalletId(String? walletName) => (super.noSuchMethod(
|
||||
_i9.Future<String?> getWalletId(String? walletName) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getWalletId,
|
||||
[walletName],
|
||||
),
|
||||
returnValue: _i12.Future<String?>.value(),
|
||||
) as _i12.Future<String?>);
|
||||
returnValue: _i9.Future<String?>.value(),
|
||||
) as _i9.Future<String?>);
|
||||
@override
|
||||
_i12.Future<bool> isMnemonicVerified({required String? walletId}) =>
|
||||
_i9.Future<bool> isMnemonicVerified({required String? walletId}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#isMnemonicVerified,
|
||||
[],
|
||||
{#walletId: walletId},
|
||||
),
|
||||
returnValue: _i12.Future<bool>.value(false),
|
||||
) as _i12.Future<bool>);
|
||||
returnValue: _i9.Future<bool>.value(false),
|
||||
) as _i9.Future<bool>);
|
||||
@override
|
||||
_i12.Future<void> setMnemonicVerified({required String? walletId}) =>
|
||||
_i9.Future<void> setMnemonicVerified({required String? walletId}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#setMnemonicVerified,
|
||||
[],
|
||||
{#walletId: walletId},
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
_i12.Future<int> deleteWallet(
|
||||
_i9.Future<int> deleteWallet(
|
||||
String? name,
|
||||
bool? shouldNotifyListeners,
|
||||
) =>
|
||||
|
@ -429,20 +394,20 @@ class MockWalletsService extends _i1.Mock implements _i15.WalletsService {
|
|||
shouldNotifyListeners,
|
||||
],
|
||||
),
|
||||
returnValue: _i12.Future<int>.value(0),
|
||||
) as _i12.Future<int>);
|
||||
returnValue: _i9.Future<int>.value(0),
|
||||
) as _i9.Future<int>);
|
||||
@override
|
||||
_i12.Future<void> refreshWallets(bool? shouldNotifyListeners) =>
|
||||
_i9.Future<void> refreshWallets(bool? shouldNotifyListeners) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#refreshWallets,
|
||||
[shouldNotifyListeners],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
void addListener(_i17.VoidCallback? listener) => super.noSuchMethod(
|
||||
void addListener(_i14.VoidCallback? listener) => super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#addListener,
|
||||
[listener],
|
||||
|
@ -450,7 +415,7 @@ class MockWalletsService extends _i1.Mock implements _i15.WalletsService {
|
|||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
void removeListener(_i17.VoidCallback? listener) => super.noSuchMethod(
|
||||
void removeListener(_i14.VoidCallback? listener) => super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#removeListener,
|
||||
[listener],
|
||||
|
@ -478,7 +443,7 @@ class MockWalletsService extends _i1.Mock implements _i15.WalletsService {
|
|||
/// A class which mocks [ThemeService].
|
||||
///
|
||||
/// See the documentation for Mockito's code generation for more information.
|
||||
class MockThemeService extends _i1.Mock implements _i18.ThemeService {
|
||||
class MockThemeService extends _i1.Mock implements _i15.ThemeService {
|
||||
MockThemeService() {
|
||||
_i1.throwOnMissingStub(this);
|
||||
}
|
||||
|
@ -508,10 +473,10 @@ class MockThemeService extends _i1.Mock implements _i18.ThemeService {
|
|||
),
|
||||
) as _i3.MainDB);
|
||||
@override
|
||||
List<_i19.StackTheme> get installedThemes => (super.noSuchMethod(
|
||||
List<_i16.StackTheme> get installedThemes => (super.noSuchMethod(
|
||||
Invocation.getter(#installedThemes),
|
||||
returnValue: <_i19.StackTheme>[],
|
||||
) as List<_i19.StackTheme>);
|
||||
returnValue: <_i16.StackTheme>[],
|
||||
) as List<_i16.StackTheme>);
|
||||
@override
|
||||
void init(_i3.MainDB? db) => super.noSuchMethod(
|
||||
Invocation.method(
|
||||
|
@ -521,73 +486,73 @@ class MockThemeService extends _i1.Mock implements _i18.ThemeService {
|
|||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
_i12.Future<void> install({required _i20.Uint8List? themeArchiveData}) =>
|
||||
_i9.Future<void> install({required _i17.Uint8List? themeArchiveData}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#install,
|
||||
[],
|
||||
{#themeArchiveData: themeArchiveData},
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
_i12.Future<void> remove({required String? themeId}) => (super.noSuchMethod(
|
||||
_i9.Future<void> remove({required String? themeId}) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#remove,
|
||||
[],
|
||||
{#themeId: themeId},
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
_i12.Future<void> checkDefaultThemesOnStartup() => (super.noSuchMethod(
|
||||
_i9.Future<void> checkDefaultThemesOnStartup() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#checkDefaultThemesOnStartup,
|
||||
[],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
_i12.Future<bool> verifyInstalled({required String? themeId}) =>
|
||||
_i9.Future<bool> verifyInstalled({required String? themeId}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#verifyInstalled,
|
||||
[],
|
||||
{#themeId: themeId},
|
||||
),
|
||||
returnValue: _i12.Future<bool>.value(false),
|
||||
) as _i12.Future<bool>);
|
||||
returnValue: _i9.Future<bool>.value(false),
|
||||
) as _i9.Future<bool>);
|
||||
@override
|
||||
_i12.Future<List<_i18.StackThemeMetaData>> fetchThemes() =>
|
||||
_i9.Future<List<_i15.StackThemeMetaData>> fetchThemes() =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#fetchThemes,
|
||||
[],
|
||||
),
|
||||
returnValue: _i12.Future<List<_i18.StackThemeMetaData>>.value(
|
||||
<_i18.StackThemeMetaData>[]),
|
||||
) as _i12.Future<List<_i18.StackThemeMetaData>>);
|
||||
returnValue: _i9.Future<List<_i15.StackThemeMetaData>>.value(
|
||||
<_i15.StackThemeMetaData>[]),
|
||||
) as _i9.Future<List<_i15.StackThemeMetaData>>);
|
||||
@override
|
||||
_i12.Future<_i20.Uint8List> fetchTheme(
|
||||
{required _i18.StackThemeMetaData? themeMetaData}) =>
|
||||
_i9.Future<_i17.Uint8List> fetchTheme(
|
||||
{required _i15.StackThemeMetaData? themeMetaData}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#fetchTheme,
|
||||
[],
|
||||
{#themeMetaData: themeMetaData},
|
||||
),
|
||||
returnValue: _i12.Future<_i20.Uint8List>.value(_i20.Uint8List(0)),
|
||||
) as _i12.Future<_i20.Uint8List>);
|
||||
returnValue: _i9.Future<_i17.Uint8List>.value(_i17.Uint8List(0)),
|
||||
) as _i9.Future<_i17.Uint8List>);
|
||||
@override
|
||||
_i19.StackTheme? getTheme({required String? themeId}) =>
|
||||
_i16.StackTheme? getTheme({required String? themeId}) =>
|
||||
(super.noSuchMethod(Invocation.method(
|
||||
#getTheme,
|
||||
[],
|
||||
{#themeId: themeId},
|
||||
)) as _i19.StackTheme?);
|
||||
)) as _i16.StackTheme?);
|
||||
}
|
||||
|
||||
/// A class which mocks [NodeService].
|
||||
|
@ -603,33 +568,33 @@ class MockNodeService extends _i1.Mock implements _i2.NodeService {
|
|||
),
|
||||
) as _i7.SecureStorageInterface);
|
||||
@override
|
||||
List<_i21.NodeModel> get primaryNodes => (super.noSuchMethod(
|
||||
List<_i18.NodeModel> get primaryNodes => (super.noSuchMethod(
|
||||
Invocation.getter(#primaryNodes),
|
||||
returnValue: <_i21.NodeModel>[],
|
||||
) as List<_i21.NodeModel>);
|
||||
returnValue: <_i18.NodeModel>[],
|
||||
) as List<_i18.NodeModel>);
|
||||
@override
|
||||
List<_i21.NodeModel> get nodes => (super.noSuchMethod(
|
||||
List<_i18.NodeModel> get nodes => (super.noSuchMethod(
|
||||
Invocation.getter(#nodes),
|
||||
returnValue: <_i21.NodeModel>[],
|
||||
) as List<_i21.NodeModel>);
|
||||
returnValue: <_i18.NodeModel>[],
|
||||
) as List<_i18.NodeModel>);
|
||||
@override
|
||||
bool get hasListeners => (super.noSuchMethod(
|
||||
Invocation.getter(#hasListeners),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
_i12.Future<void> updateDefaults() => (super.noSuchMethod(
|
||||
_i9.Future<void> updateDefaults() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#updateDefaults,
|
||||
[],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
_i12.Future<void> setPrimaryNodeFor({
|
||||
required _i16.Coin? coin,
|
||||
required _i21.NodeModel? node,
|
||||
_i9.Future<void> setPrimaryNodeFor({
|
||||
required _i13.Coin? coin,
|
||||
required _i18.NodeModel? node,
|
||||
bool? shouldNotifyListeners = false,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
|
@ -642,44 +607,44 @@ class MockNodeService extends _i1.Mock implements _i2.NodeService {
|
|||
#shouldNotifyListeners: shouldNotifyListeners,
|
||||
},
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
_i21.NodeModel? getPrimaryNodeFor({required _i16.Coin? coin}) =>
|
||||
_i18.NodeModel? getPrimaryNodeFor({required _i13.Coin? coin}) =>
|
||||
(super.noSuchMethod(Invocation.method(
|
||||
#getPrimaryNodeFor,
|
||||
[],
|
||||
{#coin: coin},
|
||||
)) as _i21.NodeModel?);
|
||||
)) as _i18.NodeModel?);
|
||||
@override
|
||||
List<_i21.NodeModel> getNodesFor(_i16.Coin? coin) => (super.noSuchMethod(
|
||||
List<_i18.NodeModel> getNodesFor(_i13.Coin? coin) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#getNodesFor,
|
||||
[coin],
|
||||
),
|
||||
returnValue: <_i21.NodeModel>[],
|
||||
) as List<_i21.NodeModel>);
|
||||
returnValue: <_i18.NodeModel>[],
|
||||
) as List<_i18.NodeModel>);
|
||||
@override
|
||||
_i21.NodeModel? getNodeById({required String? id}) =>
|
||||
_i18.NodeModel? getNodeById({required String? id}) =>
|
||||
(super.noSuchMethod(Invocation.method(
|
||||
#getNodeById,
|
||||
[],
|
||||
{#id: id},
|
||||
)) as _i21.NodeModel?);
|
||||
)) as _i18.NodeModel?);
|
||||
@override
|
||||
List<_i21.NodeModel> failoverNodesFor({required _i16.Coin? coin}) =>
|
||||
List<_i18.NodeModel> failoverNodesFor({required _i13.Coin? coin}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#failoverNodesFor,
|
||||
[],
|
||||
{#coin: coin},
|
||||
),
|
||||
returnValue: <_i21.NodeModel>[],
|
||||
) as List<_i21.NodeModel>);
|
||||
returnValue: <_i18.NodeModel>[],
|
||||
) as List<_i18.NodeModel>);
|
||||
@override
|
||||
_i12.Future<void> add(
|
||||
_i21.NodeModel? node,
|
||||
_i9.Future<void> add(
|
||||
_i18.NodeModel? node,
|
||||
String? password,
|
||||
bool? shouldNotifyListeners,
|
||||
) =>
|
||||
|
@ -692,11 +657,11 @@ class MockNodeService extends _i1.Mock implements _i2.NodeService {
|
|||
shouldNotifyListeners,
|
||||
],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
_i12.Future<void> delete(
|
||||
_i9.Future<void> delete(
|
||||
String? id,
|
||||
bool? shouldNotifyListeners,
|
||||
) =>
|
||||
|
@ -708,11 +673,11 @@ class MockNodeService extends _i1.Mock implements _i2.NodeService {
|
|||
shouldNotifyListeners,
|
||||
],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
_i12.Future<void> setEnabledState(
|
||||
_i9.Future<void> setEnabledState(
|
||||
String? id,
|
||||
bool? enabled,
|
||||
bool? shouldNotifyListeners,
|
||||
|
@ -726,12 +691,12 @@ class MockNodeService extends _i1.Mock implements _i2.NodeService {
|
|||
shouldNotifyListeners,
|
||||
],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
_i12.Future<void> edit(
|
||||
_i21.NodeModel? editedNode,
|
||||
_i9.Future<void> edit(
|
||||
_i18.NodeModel? editedNode,
|
||||
String? password,
|
||||
bool? shouldNotifyListeners,
|
||||
) =>
|
||||
|
@ -744,20 +709,20 @@ class MockNodeService extends _i1.Mock implements _i2.NodeService {
|
|||
shouldNotifyListeners,
|
||||
],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
_i12.Future<void> updateCommunityNodes() => (super.noSuchMethod(
|
||||
_i9.Future<void> updateCommunityNodes() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#updateCommunityNodes,
|
||||
[],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
returnValue: _i9.Future<void>.value(),
|
||||
returnValueForMissingStub: _i9.Future<void>.value(),
|
||||
) as _i9.Future<void>);
|
||||
@override
|
||||
void addListener(_i17.VoidCallback? listener) => super.noSuchMethod(
|
||||
void addListener(_i14.VoidCallback? listener) => super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#addListener,
|
||||
[listener],
|
||||
|
@ -765,7 +730,7 @@ class MockNodeService extends _i1.Mock implements _i2.NodeService {
|
|||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
void removeListener(_i17.VoidCallback? listener) => super.noSuchMethod(
|
||||
void removeListener(_i14.VoidCallback? listener) => super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#removeListener,
|
||||
[listener],
|
||||
|
@ -789,312 +754,3 @@ class MockNodeService extends _i1.Mock implements _i2.NodeService {
|
|||
returnValueForMissingStub: null,
|
||||
);
|
||||
}
|
||||
|
||||
/// A class which mocks [CoinServiceAPI].
|
||||
///
|
||||
/// See the documentation for Mockito's code generation for more information.
|
||||
class MockCoinServiceAPI extends _i1.Mock implements _i22.CoinServiceAPI {
|
||||
@override
|
||||
set onIsActiveWalletChanged(void Function(bool)? _onIsActiveWalletChanged) =>
|
||||
super.noSuchMethod(
|
||||
Invocation.setter(
|
||||
#onIsActiveWalletChanged,
|
||||
_onIsActiveWalletChanged,
|
||||
),
|
||||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
_i16.Coin get coin => (super.noSuchMethod(
|
||||
Invocation.getter(#coin),
|
||||
returnValue: _i16.Coin.bitcoin,
|
||||
) as _i16.Coin);
|
||||
@override
|
||||
bool get isRefreshing => (super.noSuchMethod(
|
||||
Invocation.getter(#isRefreshing),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
bool get shouldAutoSync => (super.noSuchMethod(
|
||||
Invocation.getter(#shouldAutoSync),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
set shouldAutoSync(bool? shouldAutoSync) => super.noSuchMethod(
|
||||
Invocation.setter(
|
||||
#shouldAutoSync,
|
||||
shouldAutoSync,
|
||||
),
|
||||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
bool get isFavorite => (super.noSuchMethod(
|
||||
Invocation.getter(#isFavorite),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
set isFavorite(bool? markFavorite) => super.noSuchMethod(
|
||||
Invocation.setter(
|
||||
#isFavorite,
|
||||
markFavorite,
|
||||
),
|
||||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
_i12.Future<_i8.FeeObject> get fees => (super.noSuchMethod(
|
||||
Invocation.getter(#fees),
|
||||
returnValue: _i12.Future<_i8.FeeObject>.value(_FakeFeeObject_5(
|
||||
this,
|
||||
Invocation.getter(#fees),
|
||||
)),
|
||||
) as _i12.Future<_i8.FeeObject>);
|
||||
@override
|
||||
_i12.Future<int> get maxFee => (super.noSuchMethod(
|
||||
Invocation.getter(#maxFee),
|
||||
returnValue: _i12.Future<int>.value(0),
|
||||
) as _i12.Future<int>);
|
||||
@override
|
||||
_i12.Future<String> get currentReceivingAddress => (super.noSuchMethod(
|
||||
Invocation.getter(#currentReceivingAddress),
|
||||
returnValue: _i12.Future<String>.value(''),
|
||||
) as _i12.Future<String>);
|
||||
@override
|
||||
_i9.Balance get balance => (super.noSuchMethod(
|
||||
Invocation.getter(#balance),
|
||||
returnValue: _FakeBalance_6(
|
||||
this,
|
||||
Invocation.getter(#balance),
|
||||
),
|
||||
) as _i9.Balance);
|
||||
@override
|
||||
_i12.Future<List<_i23.Transaction>> get transactions => (super.noSuchMethod(
|
||||
Invocation.getter(#transactions),
|
||||
returnValue:
|
||||
_i12.Future<List<_i23.Transaction>>.value(<_i23.Transaction>[]),
|
||||
) as _i12.Future<List<_i23.Transaction>>);
|
||||
@override
|
||||
_i12.Future<List<_i23.UTXO>> get utxos => (super.noSuchMethod(
|
||||
Invocation.getter(#utxos),
|
||||
returnValue: _i12.Future<List<_i23.UTXO>>.value(<_i23.UTXO>[]),
|
||||
) as _i12.Future<List<_i23.UTXO>>);
|
||||
@override
|
||||
set walletName(String? newName) => super.noSuchMethod(
|
||||
Invocation.setter(
|
||||
#walletName,
|
||||
newName,
|
||||
),
|
||||
returnValueForMissingStub: null,
|
||||
);
|
||||
@override
|
||||
String get walletName => (super.noSuchMethod(
|
||||
Invocation.getter(#walletName),
|
||||
returnValue: '',
|
||||
) as String);
|
||||
@override
|
||||
String get walletId => (super.noSuchMethod(
|
||||
Invocation.getter(#walletId),
|
||||
returnValue: '',
|
||||
) as String);
|
||||
@override
|
||||
_i12.Future<List<String>> get mnemonic => (super.noSuchMethod(
|
||||
Invocation.getter(#mnemonic),
|
||||
returnValue: _i12.Future<List<String>>.value(<String>[]),
|
||||
) as _i12.Future<List<String>>);
|
||||
@override
|
||||
_i12.Future<String?> get mnemonicString => (super.noSuchMethod(
|
||||
Invocation.getter(#mnemonicString),
|
||||
returnValue: _i12.Future<String?>.value(),
|
||||
) as _i12.Future<String?>);
|
||||
@override
|
||||
_i12.Future<String?> get mnemonicPassphrase => (super.noSuchMethod(
|
||||
Invocation.getter(#mnemonicPassphrase),
|
||||
returnValue: _i12.Future<String?>.value(),
|
||||
) as _i12.Future<String?>);
|
||||
@override
|
||||
bool get hasCalledExit => (super.noSuchMethod(
|
||||
Invocation.getter(#hasCalledExit),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
bool get isConnected => (super.noSuchMethod(
|
||||
Invocation.getter(#isConnected),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
int get storedChainHeight => (super.noSuchMethod(
|
||||
Invocation.getter(#storedChainHeight),
|
||||
returnValue: 0,
|
||||
) as int);
|
||||
@override
|
||||
_i12.Future<Map<String, dynamic>> prepareSend({
|
||||
required String? address,
|
||||
required _i10.Amount? amount,
|
||||
Map<String, dynamic>? args,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#prepareSend,
|
||||
[],
|
||||
{
|
||||
#address: address,
|
||||
#amount: amount,
|
||||
#args: args,
|
||||
},
|
||||
),
|
||||
returnValue:
|
||||
_i12.Future<Map<String, dynamic>>.value(<String, dynamic>{}),
|
||||
) as _i12.Future<Map<String, dynamic>>);
|
||||
@override
|
||||
_i12.Future<String> confirmSend({required Map<String, dynamic>? txData}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#confirmSend,
|
||||
[],
|
||||
{#txData: txData},
|
||||
),
|
||||
returnValue: _i12.Future<String>.value(''),
|
||||
) as _i12.Future<String>);
|
||||
@override
|
||||
_i12.Future<void> refresh() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#refresh,
|
||||
[],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
@override
|
||||
_i12.Future<void> updateNode(bool? shouldRefresh) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#updateNode,
|
||||
[shouldRefresh],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
@override
|
||||
bool validateAddress(String? address) => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#validateAddress,
|
||||
[address],
|
||||
),
|
||||
returnValue: false,
|
||||
) as bool);
|
||||
@override
|
||||
_i12.Future<bool> testNetworkConnection() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#testNetworkConnection,
|
||||
[],
|
||||
),
|
||||
returnValue: _i12.Future<bool>.value(false),
|
||||
) as _i12.Future<bool>);
|
||||
@override
|
||||
_i12.Future<void> recoverFromMnemonic({
|
||||
required String? mnemonic,
|
||||
String? mnemonicPassphrase,
|
||||
required int? maxUnusedAddressGap,
|
||||
required int? maxNumberOfIndexesToCheck,
|
||||
required int? height,
|
||||
}) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#recoverFromMnemonic,
|
||||
[],
|
||||
{
|
||||
#mnemonic: mnemonic,
|
||||
#mnemonicPassphrase: mnemonicPassphrase,
|
||||
#maxUnusedAddressGap: maxUnusedAddressGap,
|
||||
#maxNumberOfIndexesToCheck: maxNumberOfIndexesToCheck,
|
||||
#height: height,
|
||||
},
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
@override
|
||||
_i12.Future<void> initializeNew(
|
||||
({String mnemonicPassphrase, int wordCount})? data) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#initializeNew,
|
||||
[data],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
@override
|
||||
_i12.Future<void> initializeExisting() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#initializeExisting,
|
||||
[],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
@override
|
||||
_i12.Future<void> exit() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#exit,
|
||||
[],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
@override
|
||||
_i12.Future<void> fullRescan(
|
||||
int? maxUnusedAddressGap,
|
||||
int? maxNumberOfIndexesToCheck,
|
||||
) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#fullRescan,
|
||||
[
|
||||
maxUnusedAddressGap,
|
||||
maxNumberOfIndexesToCheck,
|
||||
],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
@override
|
||||
_i12.Future<_i10.Amount> estimateFeeFor(
|
||||
_i10.Amount? amount,
|
||||
int? feeRate,
|
||||
) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#estimateFeeFor,
|
||||
[
|
||||
amount,
|
||||
feeRate,
|
||||
],
|
||||
),
|
||||
returnValue: _i12.Future<_i10.Amount>.value(_FakeAmount_7(
|
||||
this,
|
||||
Invocation.method(
|
||||
#estimateFeeFor,
|
||||
[
|
||||
amount,
|
||||
feeRate,
|
||||
],
|
||||
),
|
||||
)),
|
||||
) as _i12.Future<_i10.Amount>);
|
||||
@override
|
||||
_i12.Future<bool> generateNewAddress() => (super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#generateNewAddress,
|
||||
[],
|
||||
),
|
||||
returnValue: _i12.Future<bool>.value(false),
|
||||
) as _i12.Future<bool>);
|
||||
@override
|
||||
_i12.Future<void> updateSentCachedTxData(Map<String, dynamic>? txData) =>
|
||||
(super.noSuchMethod(
|
||||
Invocation.method(
|
||||
#updateSentCachedTxData,
|
||||
[txData],
|
||||
),
|
||||
returnValue: _i12.Future<void>.value(),
|
||||
returnValueForMissingStub: _i12.Future<void>.value(),
|
||||
) as _i12.Future<void>);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue