mirror of
https://github.com/d0zingcat/gocryptotrader.git
synced 2026-05-29 15:10:37 +00:00
Added Confirm and Delete ECS tests.
This commit is contained in:
committed by
Adrian Gallagher
parent
83b0bad4e6
commit
66cc94d310
@@ -66,7 +66,7 @@ func TestConfirmJson(t *testing.T) {
|
||||
if err != nil {
|
||||
t.Errorf("Test failed. TestConfirmJson: %s", err)
|
||||
}
|
||||
err2 := config.ConfirmConfigJSON(testConfirmJson, result)
|
||||
err2 := config.ConfirmConfigJSON(testConfirmJson, &result)
|
||||
if err2 != nil {
|
||||
t.Errorf("Test failed. TestConfirmJson: %s", err2)
|
||||
}
|
||||
@@ -74,3 +74,23 @@ func TestConfirmJson(t *testing.T) {
|
||||
t.Errorf("Test failed. TestConfirmJson: Error Unmarshalling JSON")
|
||||
}
|
||||
}
|
||||
|
||||
func TestConfirmECS(t *testing.T) {
|
||||
t.Parallel()
|
||||
|
||||
ECStest := []byte("THORS-HAMMER")
|
||||
if !config.ConfirmECS(ECStest) {
|
||||
t.Errorf("Test failed. TestConfirmECS: Error finding ECS.")
|
||||
}
|
||||
}
|
||||
|
||||
func TestRemoveECS(t *testing.T) {
|
||||
t.Parallel()
|
||||
|
||||
ECStest := []byte("THORS-HAMMER")
|
||||
isremoved := config.RemoveECS(ECStest)
|
||||
|
||||
if string(isremoved) != "" {
|
||||
t.Errorf("Test failed. TestConfirmECS: Error ECS not deleted.")
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user