test(datastore/fetch): Makes sure err is not nil

This commit is contained in:
Camilo Aguilar 2014-05-16 16:57:58 -04:00
parent 4b6fc63e8c
commit 36efcc9d69

View File

@ -112,7 +112,7 @@ func TestFetchURLMalformed(t *testing.T) {
for _, test := range tests {
_, err := fetchURL(test.url)
if err != nil && err.Error() != test.want {
if err == nil || err.Error() != test.want {
t.Errorf("Incorrect result\ngot: %v\nwant: %v", err, test.want)
}
}