From 67b6ebeb9cc410d4d5ef2246cefb005bd742c835 Mon Sep 17 00:00:00 2001 From: Simon Warta Date: Tue, 4 Apr 2023 00:40:06 +0200 Subject: [PATCH] Add field name to UFraction{ to make linter happy --- ibc_test.go | 4 ++-- lib_test.go | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ibc_test.go b/ibc_test.go index fd1df5710..93576a071 100644 --- a/ibc_test.go +++ b/ibc_test.go @@ -92,7 +92,7 @@ func TestIBCHandshake(t *testing.T) { vm := withVM(t) checksum := createTestContract(t, vm, IBC_TEST_CONTRACT) gasMeter1 := api.NewMockGasMeter(TESTING_GAS_LIMIT) - deserCost := types.UFraction{1, 1} + deserCost := types.UFraction{Numerator: 1, Denominator: 1} // instantiate it with this store store := api.NewLookup(gasMeter1) goapi := api.NewMockAPI() @@ -159,7 +159,7 @@ func TestIBCPacketDispatch(t *testing.T) { vm := withVM(t) checksum := createTestContract(t, vm, IBC_TEST_CONTRACT) gasMeter1 := api.NewMockGasMeter(TESTING_GAS_LIMIT) - deserCost := types.UFraction{1, 1} + deserCost := types.UFraction{Numerator: 1, Denominator: 1} // instantiate it with this store store := api.NewLookup(gasMeter1) goapi := api.NewMockAPI() diff --git a/lib_test.go b/lib_test.go index a1862319f..0f8055b2b 100644 --- a/lib_test.go +++ b/lib_test.go @@ -134,7 +134,7 @@ func TestHappyPath(t *testing.T) { vm := withVM(t) checksum := createTestContract(t, vm, HACKATOM_TEST_CONTRACT) - deserCost := types.UFraction{1, 1} + deserCost := types.UFraction{Numerator: 1, Denominator: 1} gasMeter1 := api.NewMockGasMeter(TESTING_GAS_LIMIT) // instantiate it with this store store := api.NewLookup(gasMeter1) @@ -175,7 +175,7 @@ func TestEnv(t *testing.T) { vm := withVM(t) checksum := createTestContract(t, vm, CYBERPUNK_TEST_CONTRACT) - deserCost := types.UFraction{1, 1} + deserCost := types.UFraction{Numerator: 1, Denominator: 1} gasMeter1 := api.NewMockGasMeter(TESTING_GAS_LIMIT) // instantiate it with this store store := api.NewLookup(gasMeter1) @@ -242,7 +242,7 @@ func TestGetMetrics(t *testing.T) { // Create contract checksum := createTestContract(t, vm, HACKATOM_TEST_CONTRACT) - deserCost := types.UFraction{1, 1} + deserCost := types.UFraction{Numerator: 1, Denominator: 1} // GetMetrics 2 metrics, err = vm.GetMetrics()