diff options
author | Patrick Steinhardt <psteinhardt@gitlab.com> | 2022-12-14 14:05:21 +0300 |
---|---|---|
committer | Patrick Steinhardt <psteinhardt@gitlab.com> | 2022-12-14 14:05:21 +0300 |
commit | f21f0c4c916f149b234ae39a23a3bb9ce8c5c346 (patch) | |
tree | 59ac9d67bab1ede96f252b02e858ca44ef1f9f53 /internal/helper/error_test.go | |
parent | 2175c8a8f4519bc6a286eb289285e0bf720a67f5 (diff) |
helper: Convert and drop usage of `ErrAbortedf()`
Convert callers of `ErrAbortedf()` to instead use the
`structerr` package. Remove the now-unused function.
Diffstat (limited to 'internal/helper/error_test.go')
-rw-r--r-- | internal/helper/error_test.go | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/internal/helper/error_test.go b/internal/helper/error_test.go index 65a625297..c4f4e7841 100644 --- a/internal/helper/error_test.go +++ b/internal/helper/error_test.go @@ -45,11 +45,6 @@ func TestErrorf(t *testing.T) { expectedCode: codes.NotFound, }, { - desc: "ErrAbortedf", - errorf: ErrAbortedf, - expectedCode: codes.Aborted, - }, - { desc: "ErrDataLossf", errorf: ErrDataLossf, expectedCode: codes.DataLoss, @@ -221,7 +216,7 @@ func TestGrpcCode(t *testing.T) { exp: codes.NotFound, }, "double helper wrapped status": { - in: ErrAbortedf("outer: %w", fmt.Errorf("context: %w", ErrNotFoundf(""))), + in: ErrFailedPreconditionf("outer: %w", fmt.Errorf("context: %w", ErrNotFoundf(""))), exp: codes.NotFound, }, "nil input": { |