diff --git a/lib/pages/tabs/bmm_tab_page.dart b/lib/pages/tabs/bmm_tab_page.dart index a41b0f6c..79b38b41 100644 --- a/lib/pages/tabs/bmm_tab_page.dart +++ b/lib/pages/tabs/bmm_tab_page.dart @@ -130,6 +130,7 @@ class BlindMergedMiningTabPage extends StatelessWidget { physics: const NeverScrollableScrollPhysics(), itemCount: viewModel.bmmAttempts.length, itemBuilder: (context, index) => BMMAttemptView( + key: ValueKey(viewModel.bmmAttempts[index].result.txid), bmmAttempt: viewModel.bmmAttempts[index], onPressed: () => viewModel.toggleRunning(false), ), @@ -224,7 +225,8 @@ class BlindMergedMiningTabPageViewModel extends BaseViewModel { // Ported from SidechainBMMTableModel::AddAttempt in the testchain codebase void _addAttempt(BmmAttempt attempt) { - bmmAttempts.add( + bmmAttempts.insert( + 0, attempt, ); diff --git a/test/mocks/rpc_mock_sidechain.dart b/test/mocks/rpc_mock_sidechain.dart index 05d49ff5..8727d2f2 100644 --- a/test/mocks/rpc_mock_sidechain.dart +++ b/test/mocks/rpc_mock_sidechain.dart @@ -1,4 +1,3 @@ -import 'package:sidesail/pages/tabs/settings_tab.dart'; import 'package:sidesail/rpc/rpc_sidechain.dart'; class MockSidechainRPC extends SidechainRPC { @@ -82,15 +81,6 @@ class MockSidechainRPC extends SidechainRPC { return (true, null); } - @override - SingleNodeConnectionSettings connectionSettings = SingleNodeConnectionSettings( - '/path/to/chain.conf', - 'host', - 2121, - 'username', - 'password', - ); - @override Future createClient() async { return;