Extract storage diff fetching behind an interface

- Replaces directly reading from a CSV
- Simplifies testing
- Should hopefully make it easier to plug in other sources for storage
  diffs (e.g. differently formatted CSVs, JSON RPC, etc)
This commit is contained in:
Rob Mulholand
2019-05-01 12:30:36 -05:00
parent c93e6adb27
commit 2d684c5aec
15 changed files with 279 additions and 224 deletions
+2
View File
@@ -23,9 +23,11 @@ import (
type MockStorageQueue struct {
AddCalled bool
AddError error
PassedRow utils.StorageDiffRow
}
func (queue *MockStorageQueue) Add(row utils.StorageDiffRow) error {
queue.AddCalled = true
queue.PassedRow = row
return queue.AddError
}