Skip to content

Commit

Permalink
fix serviceMetadata_test.go
Browse files Browse the repository at this point in the history
  • Loading branch information
semyon-dev committed Nov 14, 2024
1 parent c22e165 commit 8cb5c1d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion blockchain/serviceMetadata_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ func TestTiers(t *testing.T) {
assert.Equal(t, metaData.GetLicenses().Tiers[0].Range[0].DiscountInPercentage,
1.0)
}

func TestInitServiceMetaDataFromJson(t *testing.T) {
//Parse Bad JSON
_, err := InitServiceMetaDataFromJson([]byte(strings.Replace(testJsonData, "{", "", 1)))
Expand All @@ -69,7 +70,7 @@ func TestInitServiceMetaDataFromJson(t *testing.T) {
//Parse Bad JSON
_, err = InitServiceMetaDataFromJson([]byte(strings.Replace(testJsonData, "0x7DF35C98f41F3Af0df1dc4c7F7D4C19a71Dd059F", "", 1)))
if err != nil {
assert.Equal(t, err.Error(), "MetaData does not have 'free_call_signer_address defined correctly")
assert.Contains(t, err.Error(), "MetaData does not have 'free_call_signer_address defined correctly")
}
_, err = InitServiceMetaDataFromJson([]byte(strings.Replace(testJsonData, "default_pricing", "dummy", 1)))
if err != nil {
Expand Down

0 comments on commit 8cb5c1d

Please sign in to comment.