Skip to content

Commit

Permalink
rename to bool to avoid the case bug
Browse files Browse the repository at this point in the history
  • Loading branch information
containerman17 committed Oct 10, 2024
1 parent bbf2d24 commit 7f7722a
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 7 deletions.
2 changes: 1 addition & 1 deletion abi/abi_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ func TestNewABI(t *testing.T) {
Outer{},
ActionWithOutput{},
FixedBytes{},
Booleans{},
Bools{},
}, []codec.Typed{
ActionOutput{},
})
Expand Down
2 changes: 1 addition & 1 deletion abi/auto_marshal_abi_spec_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ func TestMarshalSpecs(t *testing.T) {
{"strOnly", &MockObjectStringAndBytes{}},
{"outer", &Outer{}},
{"fixedBytes", &FixedBytes{}},
{"booleans", &Booleans{}},
{"bools", &Bools{}},
}

for _, tc := range testCases {
Expand Down
4 changes: 2 additions & 2 deletions abi/mockabi_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ type FixedBytes struct {
ThirtyTwoBytes [32]uint8 `serialize:"true" json:"thirtyTwoBytes"`
}

type Booleans struct {
type Bools struct {
Bool1 bool `serialize:"true" json:"bool1"`
Bool2 bool `serialize:"true" json:"bool2"`
BoolArray []bool `serialize:"true" json:"boolArray"`
Expand Down Expand Up @@ -120,7 +120,7 @@ func (FixedBytes) GetTypeID() uint8 {
return 9
}

func (Booleans) GetTypeID() uint8 {
func (Bools) GetTypeID() uint8 {
return 10
}

Expand Down
2 changes: 1 addition & 1 deletion abi/testdata/abi.hash.hex
Original file line number Diff line number Diff line change
@@ -1 +1 @@
58a84810851491da7378318c3439393ba91da1e85dab59d39ca5a6da16a90345
3b634237434bc35076e790b52986d735f30d582e9b7b94ad357d91b33072e284
4 changes: 2 additions & 2 deletions abi/testdata/abi.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
},
{
"id": 10,
"name": "Booleans"
"name": "Bools"
}
],
"outputs": [
Expand Down Expand Up @@ -236,7 +236,7 @@
]
},
{
"name": "Booleans",
"name": "Bools",
"fields": [
{
"name": "bool1",
Expand Down
File renamed without changes.
9 changes: 9 additions & 0 deletions abi/testdata/bools.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"bool1": false,
"bool2": true,
"boolArray": [
true,
false,
true
]
}

0 comments on commit 7f7722a

Please sign in to comment.