From beff9d79bce9e1621bdb9732f7b543c469dd5665 Mon Sep 17 00:00:00 2001 From: Timo Riski Date: Tue, 29 Oct 2024 16:37:31 +0200 Subject: [PATCH] fix: tests using `DiskSpaceMb` --- tests/cassandra_test.go | 2 +- tests/kafka_test.go | 2 +- tests/mysql_test.go | 2 +- tests/opensearch_test.go | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/cassandra_test.go b/tests/cassandra_test.go index 595c4eb1..f645e761 100644 --- a/tests/cassandra_test.go +++ b/tests/cassandra_test.go @@ -75,7 +75,7 @@ func TestCassandra(t *testing.T) { assert.Equal(t, csAvn.Plan, cs.Spec.Plan) assert.Equal(t, csAvn.CloudName, cs.Spec.CloudName) assert.Equal(t, "450GiB", cs.Spec.DiskSpace) - assert.Equal(t, float64(460800), *csAvn.DiskSpaceMb) + assert.Equal(t, int(460800), *csAvn.DiskSpaceMb) assert.Equal(t, map[string]string{"env": "test", "instance": "foo"}, cs.Spec.Tags) csResp, err := avnClient.ServiceTags.Get(ctx, cfg.Project, name) require.NoError(t, err) diff --git a/tests/kafka_test.go b/tests/kafka_test.go index 6e42cf10..94bae7ba 100644 --- a/tests/kafka_test.go +++ b/tests/kafka_test.go @@ -76,7 +76,7 @@ func TestKafka(t *testing.T) { assert.Equal(t, ksAvn.Plan, ks.Spec.Plan) assert.Equal(t, ksAvn.CloudName, ks.Spec.CloudName) assert.Equal(t, "600GiB", ks.Spec.DiskSpace) - assert.Equal(t, float64(614400), *ksAvn.DiskSpaceMb) + assert.Equal(t, int(614400), *ksAvn.DiskSpaceMb) assert.Equal(t, map[string]string{"env": "test", "instance": "foo"}, ks.Spec.Tags) ksResp, err := avnClient.ServiceTags.Get(ctx, cfg.Project, name) require.NoError(t, err) diff --git a/tests/mysql_test.go b/tests/mysql_test.go index fc105c21..297243ae 100644 --- a/tests/mysql_test.go +++ b/tests/mysql_test.go @@ -74,7 +74,7 @@ func TestMySQL(t *testing.T) { assert.Equal(t, msAvn.Plan, ms.Spec.Plan) assert.Equal(t, msAvn.CloudName, ms.Spec.CloudName) assert.Equal(t, "100GiB", ms.Spec.DiskSpace) - assert.Equal(t, float64(102400), *msAvn.DiskSpaceMb) + assert.Equal(t, int(102400), *msAvn.DiskSpaceMb) assert.Equal(t, map[string]string{"env": "test", "instance": "foo"}, ms.Spec.Tags) msResp, err := avnClient.ServiceTags.Get(ctx, cfg.Project, name) require.NoError(t, err) diff --git a/tests/opensearch_test.go b/tests/opensearch_test.go index 4c499538..58ed7787 100644 --- a/tests/opensearch_test.go +++ b/tests/opensearch_test.go @@ -79,7 +79,7 @@ func TestOpenSearch(t *testing.T) { assert.Equal(t, osAvn.Plan, os.Spec.Plan) assert.Equal(t, osAvn.CloudName, os.Spec.CloudName) assert.Equal(t, "240GiB", os.Spec.DiskSpace) - assert.Equal(t, float64(245760), *osAvn.DiskSpaceMb) + assert.Equal(t, int(245760), *osAvn.DiskSpaceMb) assert.Equal(t, map[string]string{"env": "test", "instance": "foo"}, os.Spec.Tags) osResp, err := avnClient.ServiceTags.Get(ctx, cfg.Project, name) require.NoError(t, err)