mirror of
https://github.com/jwetzell/psn-go.git
synced 2026-08-28 10:29:15 +00:00
add most basic error handling on the decode side
This commit is contained in:
@@ -56,7 +56,12 @@ func TestChunkDecoding(t *testing.T) {
|
||||
|
||||
for _, testCase := range testCases {
|
||||
|
||||
actual := DecodeChunk(testCase.bytes)
|
||||
actual, err := DecodeChunk(testCase.bytes)
|
||||
|
||||
if err != nil {
|
||||
t.Errorf("Test '%s' failed to decode chunk properly", testCase.description)
|
||||
fmt.Println(err)
|
||||
}
|
||||
|
||||
if !reflect.DeepEqual(actual, testCase.expected) {
|
||||
t.Errorf("Test '%s' failed to decode chunk properly", testCase.description)
|
||||
|
||||
Reference in New Issue
Block a user