From 468a52737a162c32b2655944d751ab7f2f5449c4 Mon Sep 17 00:00:00 2001 From: Alexander Ewetumo Date: Wed, 25 Oct 2017 13:37:42 +0100 Subject: [PATCH] Fixing changes and url bug in accounts and transactions --- e2e/accounts/accounts_rpc_test.go | 7 +++++-- e2e/transactions/transactions_test.go | 12 ++++++++---- 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/e2e/accounts/accounts_rpc_test.go b/e2e/accounts/accounts_rpc_test.go index 681dd1efa..4085c682f 100644 --- a/e2e/accounts/accounts_rpc_test.go +++ b/e2e/accounts/accounts_rpc_test.go @@ -5,6 +5,7 @@ import ( "testing" "github.com/status-im/status-go/e2e" + "github.com/status-im/status-go/geth/params" . "github.com/status-im/status-go/testing" "github.com/stretchr/testify/suite" ) @@ -42,11 +43,13 @@ func (s *AccountsTestSuite) TestRPCEthAccountsWithUpstream() { // FIXME(tiabc): Stop skipping after https://github.com/status-im/status-go/issues/424 s.T().Skip() - s.StartTestBackend(e2e.WithUpstream("https://ropsten.infura.io/z6GCTmjdP3FETEJmMBI4")) + addr, err := GetNetworkURLFromID(params.RopstenNetworkID) + s.NoError(err) + s.StartTestBackend(e2e.WithUpstream(addr)) defer s.StopTestBackend() // log into test account - err := s.Backend.AccountManager().SelectAccount(TestConfig.Account1.Address, TestConfig.Account1.Password) + err = s.Backend.AccountManager().SelectAccount(TestConfig.Account1.Address, TestConfig.Account1.Password) s.NoError(err) rpcClient := s.Backend.NodeManager().RPCClient() diff --git a/e2e/transactions/transactions_test.go b/e2e/transactions/transactions_test.go index 20717f0fe..c24cba215 100644 --- a/e2e/transactions/transactions_test.go +++ b/e2e/transactions/transactions_test.go @@ -83,10 +83,12 @@ func (s *TransactionsTestSuite) TestCallRPCSendTransactionUpstream() { // FIXME(tiabc): Stop skipping after https://github.com/status-im/status-go/issues/424 s.T().Skip() - s.StartTestBackend(e2e.WithUpstream("https://ropsten.infura.io/nKmXgiFgc2KqtoQ8BCGJ")) + addr, err := GetNetworkURLFromID(params.RopstenNetworkID) + s.NoError(err) + s.StartTestBackend(e2e.WithUpstream(addr)) defer s.StopTestBackend() - err := s.Backend.AccountManager().SelectAccount(TestConfig.Account2.Address, TestConfig.Account2.Password) + err = s.Backend.AccountManager().SelectAccount(TestConfig.Account2.Address, TestConfig.Account2.Password) s.NoError(err) transactionCompleted := make(chan struct{}) @@ -309,10 +311,12 @@ func (s *TransactionsTestSuite) TestSendEtherTxUpstream() { // FIXME(tiabc): Stop skipping after https://github.com/status-im/status-go/issues/424 s.T().Skip() - s.StartTestBackend(e2e.WithUpstream("https://ropsten.infura.io/z6GCTmjdP3FETEJmMBI4")) + addr, err := GetNetworkURLFromID(params.RopstenNetworkID) + s.NoError(err) + s.StartTestBackend(e2e.WithUpstream(addr)) defer s.StopTestBackend() - err := s.Backend.AccountManager().SelectAccount(TestConfig.Account1.Address, TestConfig.Account1.Password) + err = s.Backend.AccountManager().SelectAccount(TestConfig.Account1.Address, TestConfig.Account1.Password) s.NoError(err) completeQueuedTransaction := make(chan struct{})