Add tests for plugin helpers

- Prevents code analysis from showing functions as unused
- Also address other code analysis issues
This commit is contained in:
Rob Mulholand
2019-03-06 12:43:39 -06:00
parent a806cb2818
commit b6bef49318
17 changed files with 390 additions and 154 deletions
+3 -3
View File
@@ -58,9 +58,9 @@ var _ = Describe("Log chunker", func() {
Describe("initialisation", func() {
It("creates lookup maps correctly", func() {
Expect(chunker.AddressToNames).To(Equal(map[string][]string{
"0x00000000000000000000000000000000000000a1": []string{"TransformerA"},
"0x00000000000000000000000000000000000000a2": []string{"TransformerA", "TransformerC"},
"0x00000000000000000000000000000000000000b1": []string{"TransformerB"},
"0x00000000000000000000000000000000000000a1": {"TransformerA"},
"0x00000000000000000000000000000000000000a2": {"TransformerA", "TransformerC"},
"0x00000000000000000000000000000000000000b1": {"TransformerB"},
}))
Expect(chunker.NameToTopic0).To(Equal(map[string]common.Hash{