Files
gocryptotrader/currency/symbol/symbol_test.go
Adrian Gallagher 55c8b02d1d Fix misspells
2017-10-04 18:15:01 +11:00

22 lines
498 B
Go

package symbol
import "testing"
func TestGetSymbolByCurrencyName(t *testing.T) {
expected := "₩"
actual, err := GetSymbolByCurrencyName("KPW")
if err != nil {
t.Errorf("Test failed. TestGetSymbolByCurrencyName error: %s", err)
}
if actual != expected {
t.Errorf("Test failed. TestGetSymbolByCurrencyName differing values")
}
_, err = GetSymbolByCurrencyName("BLAH")
if err == nil {
t.Errorf("Test failed. TestGetSymbolByCurrencyNam returned nil on non-existent currency")
}
}