From ededd190a14befedc54f9a97de220236831e9650 Mon Sep 17 00:00:00 2001 From: lumtis Date: Fri, 8 Mar 2024 22:53:58 +0100 Subject: [PATCH] initialize distribution test --- x/emissions/keeper/distributions_test.go | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 x/emissions/keeper/distributions_test.go diff --git a/x/emissions/keeper/distributions_test.go b/x/emissions/keeper/distributions_test.go new file mode 100644 index 0000000000..69c80b31d0 --- /dev/null +++ b/x/emissions/keeper/distributions_test.go @@ -0,0 +1,18 @@ +package keeper_test + +import ( + "testing" + + "github.com/stretchr/testify/require" + keepertest "github.com/zeta-chain/zetacore/testutil/keeper" +) + +func TestKeeper_GetDistributions(t *testing.T) { + k, ctx, sdkk, _ := keepertest.EmissionsKeeper(t) + + val, obs, tss := k.GetDistributions(ctx) + + require.EqualValues(t, "4810474537037037037", val.String()) // 0.5 * block reward + require.EqualValues(t, "2405237268518518518", obs.String()) // 0.25 * block reward + require.EqualValues(t, "2405237268518518518", tss.String()) // 0.25 * block reward +}