Skip to content

Commit 77cfaf4

Browse files
committed
Remove t.context from tests
Signed-off-by: Satyam Zode <[email protected]>
1 parent 1dc72c8 commit 77cfaf4

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

services/friendbot/internal/friendbot_test.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,8 @@ func TestFriendbot_Pay_accountExists(t *testing.T) {
153153
}
154154

155155
func TestFriendbot_Pay_accountExistsAlreadyFunded(t *testing.T) {
156-
ctx := t.Context()
156+
ctx, cancel := context.WithTimeout(context.Background(), 30*time.Second)
157+
defer cancel()
157158
mockSubmitTransaction := func(ctx context.Context, minion *Minion, hclient horizonclient.ClientInterface, tx string) (*hProtocol.Transaction, error) {
158159
// Instead of submitting the tx, we emulate a success.
159160
txSuccess := hProtocol.Transaction{EnvelopeXdr: tx, Successful: true}

0 commit comments

Comments
 (0)