mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2025-02-02 03:06:29 +00:00
commit
04fc595f7f
10 changed files with 37 additions and 37 deletions
2
.github/workflows/test.yaml
vendored
2
.github/workflows/test.yaml
vendored
|
@ -1,6 +1,6 @@
|
|||
#should deny
|
||||
name: Test
|
||||
on: [pull_request]
|
||||
on: [push, pull_request]
|
||||
jobs:
|
||||
test:
|
||||
runs-on: ubuntu-20.04
|
||||
|
|
|
@ -1 +1 @@
|
|||
Subproject commit 78533fa427ffc582b83cb67a766c8d38fac2abd8
|
||||
Subproject commit 6242046217abf47b61d9397ae447632b06f853fa
|
|
@ -1,5 +1,3 @@
|
|||
import 'dart:io';
|
||||
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_riverpod/flutter_riverpod.dart';
|
||||
import 'package:stackwallet/pages/add_wallet_views/add_wallet_view/sub_widgets/coin_select_item.dart';
|
||||
|
@ -15,15 +13,10 @@ class AddWalletView extends StatelessWidget {
|
|||
|
||||
static const routeName = "/addWallet";
|
||||
|
||||
final _coins = Coin.values;
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
List<Coin> coins = _coins;
|
||||
if (Platform.isIOS) {
|
||||
coins = _coins;
|
||||
}
|
||||
debugPrint("BUILD: $runtimeType");
|
||||
List<Coin> coins = [...Coin.values];
|
||||
coins.remove(Coin.firoTestNet);
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
leading: AppBarBackButton(
|
||||
|
|
|
@ -48,7 +48,9 @@ class _AddressBookViewState extends ConsumerState<AddressBookView> {
|
|||
ref.refresh(addressBookFilterProvider);
|
||||
|
||||
if (widget.coin == null) {
|
||||
final coins = Coin.values.where((e) => !(e == Coin.epicCash)).toList();
|
||||
List<Coin> coins =
|
||||
Coin.values.where((e) => !(e == Coin.epicCash)).toList();
|
||||
coins.remove(Coin.firoTestNet);
|
||||
|
||||
bool showTestNet = ref.read(prefsChangeNotifierProvider).showTestNetCoins;
|
||||
|
||||
|
|
|
@ -23,7 +23,8 @@ class _AddressBookFilterViewState extends ConsumerState<AddressBookFilterView> {
|
|||
|
||||
@override
|
||||
void initState() {
|
||||
final coins = Coin.values;
|
||||
List<Coin> coins = [...Coin.values];
|
||||
coins.remove(Coin.firoTestNet);
|
||||
|
||||
bool showTestNet = ref.read(prefsChangeNotifierProvider).showTestNetCoins;
|
||||
|
||||
|
|
|
@ -14,6 +14,8 @@ class CoinSelectSheet extends StatelessWidget {
|
|||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final maxHeight = MediaQuery.of(context).size.height * 0.60;
|
||||
var coins_ = [...Coin.values];
|
||||
coins_.remove(Coin.firoTestNet);
|
||||
return Container(
|
||||
decoration: const BoxDecoration(
|
||||
color: CFColors.white,
|
||||
|
@ -68,10 +70,10 @@ class CoinSelectSheet extends StatelessWidget {
|
|||
return ListView.builder(
|
||||
shrinkWrap: true,
|
||||
itemCount: showTestNet
|
||||
? Coin.values.length
|
||||
: Coin.values.length - kTestNetCoinCount,
|
||||
? coins_.length
|
||||
: coins_.length - kTestNetCoinCount,
|
||||
itemBuilder: (builderContext, index) {
|
||||
final coin = Coin.values[index];
|
||||
final coin = coins_[index];
|
||||
return Padding(
|
||||
padding: const EdgeInsets.symmetric(vertical: 4),
|
||||
child: RawMaterialButton(
|
||||
|
|
|
@ -23,11 +23,12 @@ class ManageNodesView extends ConsumerStatefulWidget {
|
|||
}
|
||||
|
||||
class _ManageNodesViewState extends ConsumerState<ManageNodesView> {
|
||||
List<Coin> _coins = Coin.values;
|
||||
List<Coin> _coins = [...Coin.values];
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
_coins = _coins.toList();
|
||||
_coins.remove(Coin.firoTestNet);
|
||||
super.initState();
|
||||
}
|
||||
|
||||
|
|
|
@ -726,7 +726,7 @@ Future<String> _getMintScriptWrapper(
|
|||
}
|
||||
|
||||
Future<void> _setTestnetWrapper(bool isTestnet) async {
|
||||
setTestnet(isTestnet);
|
||||
// setTestnet(isTestnet);
|
||||
}
|
||||
|
||||
/// Handles a single instance of a firo wallet
|
||||
|
|
|
@ -22,7 +22,8 @@ enum Coin {
|
|||
firoTestNet,
|
||||
}
|
||||
|
||||
const int kTestNetCoinCount = 3;
|
||||
// remove firotestnet for now
|
||||
const int kTestNetCoinCount = 2;
|
||||
|
||||
extension CoinExt on Coin {
|
||||
String get prettyName {
|
||||
|
|
|
@ -128,24 +128,24 @@ void main() {
|
|||
expect(result, 1);
|
||||
});
|
||||
|
||||
// test("isolateCreateJoinSplitTransaction success", () async {
|
||||
// final result = await isolateCreateJoinSplitTransaction(
|
||||
// 9000,
|
||||
// "aNmsUtzPzQ3SKWNjEH48GacMQJXWN5Rotm",
|
||||
// true,
|
||||
// TEST_MNEMONIC,
|
||||
// 2,
|
||||
// Decimal.ten,
|
||||
// SampleLelantus.lelantusEntries,
|
||||
// 459185,
|
||||
// Coin.firo,
|
||||
// firoNetwork,
|
||||
// [GetAnonymitySetSampleData.data],
|
||||
// "en_US",
|
||||
// );
|
||||
//
|
||||
// expect(result, isA<Map<String, dynamic>>());
|
||||
// });
|
||||
test("isolateCreateJoinSplitTransaction success", () async {
|
||||
final result = await isolateCreateJoinSplitTransaction(
|
||||
9000,
|
||||
"aNmsUtzPzQ3SKWNjEH48GacMQJXWN5Rotm",
|
||||
true,
|
||||
TEST_MNEMONIC,
|
||||
2,
|
||||
Decimal.ten,
|
||||
SampleLelantus.lelantusEntries,
|
||||
459185,
|
||||
Coin.firo,
|
||||
firoNetwork,
|
||||
[GetAnonymitySetSampleData.data],
|
||||
"en_US",
|
||||
);
|
||||
|
||||
expect(result, isA<Map<String, dynamic>>());
|
||||
});
|
||||
|
||||
test("isolateEstimateJoinSplitFee", () async {
|
||||
final result = await isolateEstimateJoinSplitFee(
|
||||
|
|
Loading…
Reference in a new issue