TestErrorf tests the initializer of error package
(t *testing.T)
| 11 | |
| 12 | // TestErrorf tests the initializer of error package |
| 13 | func TestErrorf(t *testing.T) { |
| 14 | err := errors.Errorf(errors.CodeInternal, "test internal") |
| 15 | assert.Equal(t, "test internal", err.Error()) |
| 16 | } |
| 17 | |
| 18 | // TestWrap ensures we can wrap an error and use Cause() to retrieve the original error |
| 19 | func TestWrap(t *testing.T) { |