graphql
graphql copied to clipboard
{types,graphql_test}: Adds `Result.ErrorsJoined` implementation.
Details
- Depends on: https://github.com/graphql-go/graphql/pull/718
-
types: addsResult.ErrorsJoinedmethod. -
graphql_test: addsResult.ErrorsJoined100& test coverage unit tests. -
.circleci/config.yml: upgradescirclecigo versions.
Added in order to be able to join errors because currently Result.Errors returns an slice of errors and is common use case to have it consolidated into a single error.
This PR leverages the %w error formatting verb in order to wrap errors.
Ref: https://go.dev/doc/go1.13#error_wrapping
Test Plan
:heavy_check_mark: Tested that Result.ErrorsJoined works as expected via go test -cover ...:
go clean -testcache && go test -cover -coverprofile=coverage.out ./... && go tool cover -html=coverage.out -o coverage.html; sed -i'' -e's/black/whitesmoke/g' coverage.html && open coverage.html
I'm getting to work. See my steps and track my cost here.
- [ ] Wake on any new activity. I always see new activity while actively working. When paused, I'll only respond when tagged unless this box is checked.