chore: add sleep after file and contract creation
package hedera
import (
- "github.com/stretchr/testify/assert"
"os"
"strings"
"testing"
+ "time"
+
+ "github.com/stretchr/testify/assert"
)
func TestNewContractInfoQuery(t *testing.T) {
@@ -54,6 +56,8 @@ func TestContractInfoQuery_Execute(t *testing.T) {
fileID := receipt.GetFileID()
assert.NotNil(t, fileID)
+ time.Sleep(5 * time.Second)
+
txID, err = NewContractCreateTransaction().
SetAdminKey(client.GetOperatorKey()).
SetGas(2000).
@@ -64,6 +68,8 @@ func TestContractInfoQuery_Execute(t *testing.T) {
Execute(client)
assert.NoError(t, err)
+ time.Sleep(5 * time.Second)
+
receipt, err = txID.GetReceipt(client)
assert.NoError(t, err)
