4
4
"context"
5
5
"sync"
6
6
"testing"
7
- "time"
8
7
9
8
"github.com/stellar/go/txnbuild"
10
9
@@ -15,8 +14,8 @@ import (
15
14
)
16
15
17
16
func TestFriendbot_Pay_accountDoesNotExist (t * testing.T ) {
18
- ctx , cancel := context .WithTimeout ( context . Background (), 30 * time . Second )
19
- defer cancel ()
17
+ ctx := context .Background ()
18
+
20
19
mockSubmitTransaction := func (ctx context.Context , minion * Minion , hclient horizonclient.ClientInterface , tx string ) (* hProtocol.Transaction , error ) {
21
20
// Instead of submitting the tx, we emulate a success.
22
21
txSuccess := hProtocol.Transaction {EnvelopeXdr : tx , Successful : true }
@@ -84,8 +83,7 @@ func TestFriendbot_Pay_accountDoesNotExist(t *testing.T) {
84
83
}
85
84
86
85
func TestFriendbot_Pay_accountExists (t * testing.T ) {
87
- ctx , cancel := context .WithTimeout (context .Background (), 30 * time .Second )
88
- defer cancel ()
86
+ ctx := context .Background ()
89
87
mockSubmitTransaction := func (ctx context.Context , minion * Minion , hclient horizonclient.ClientInterface , tx string ) (* hProtocol.Transaction , error ) {
90
88
// Instead of submitting the tx, we emulate a success.
91
89
txSuccess := hProtocol.Transaction {EnvelopeXdr : tx , Successful : true }
@@ -153,8 +151,7 @@ func TestFriendbot_Pay_accountExists(t *testing.T) {
153
151
}
154
152
155
153
func TestFriendbot_Pay_accountExistsAlreadyFunded (t * testing.T ) {
156
- ctx , cancel := context .WithTimeout (context .Background (), 30 * time .Second )
157
- defer cancel ()
154
+ ctx := context .Background ()
158
155
mockSubmitTransaction := func (ctx context.Context , minion * Minion , hclient horizonclient.ClientInterface , tx string ) (* hProtocol.Transaction , error ) {
159
156
// Instead of submitting the tx, we emulate a success.
160
157
txSuccess := hProtocol.Transaction {EnvelopeXdr : tx , Successful : true }
0 commit comments