Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initial #2

Merged
merged 22 commits into from
Oct 15, 2024
Merged

Initial #2

merged 22 commits into from
Oct 15, 2024

Conversation

shelleeboo
Copy link
Member

Added badges

neiljpowell and others added 15 commits October 8, 2024 14:51
- Added NewContinue for HTTP 100 Continue
- Added NewSwitchingProtocols for HTTP 101 Switching Protocols
- Added NewOK for HTTP 200 OK
- Added NewCreated for HTTP 201 Created
- Added NewAccepted for HTTP 202 Accepted
- Added NewNoContent for HTTP 204 No Content
- Added NewMovedPermanently for HTTP 301 Moved Permanently
- Added NewFound for HTTP 302 Found
- Added NewNotModified for HTTP 304 Not Modified
- Added NewUnauthorized for HTTP 401 Unauthorized
- Added NewForbidden for HTTP 403 Forbidden
- Added NewMethodNotAllowed for HTTP 405 Method Not Allowed
- Added NewConflict for HTTP 409 Conflict
- Added NewUnprocessableEntity for HTTP 422 Unprocessable Entity
- Added NewNotImplemented for HTTP 501 Not Implemented
- Added NewBadGateway for HTTP 502 Bad Gateway
- Added NewServiceUnavailable for HTTP 503 Service Unavailable

Add tests for all HTTP problem types

- Added tests for HTTP 100 Continue
- Added tests for HTTP 101 Switching Protocols
- Added tests for HTTP 200 OK
- Added tests for HTTP 201 Created
- Added tests for HTTP 202 Accepted
- Added tests for HTTP 204 No Content
- Added tests for HTTP 301 Moved Permanently
- Added tests for HTTP 302 Found
- Added tests for HTTP 304 Not Modified
- Added tests for HTTP 400 Bad Request
- Added tests for HTTP 401 Unauthorized
- Added tests for HTTP 403 Forbidden
- Added tests for HTTP 404 Not Found
- Added tests for HTTP 405 Method Not Allowed
- Added tests for HTTP 409 Conflict
- Added tests for HTTP 422 Unprocessable Entity
- Added tests for HTTP 500 Internal Server Error
- Added tests for HTTP 501 Not Implemented
- Added tests for HTTP 502 Bad Gateway
- Added tests for HTTP 503 Service Unavailable

Add ProblemType definitions for various HTTP status codes

- Added ProblemType for HTTP 100 Continue
- Added ProblemType for HTTP 101 Switching Protocols
- Added ProblemType for HTTP 200 OK
- Added ProblemType for HTTP 201 Created
- Added ProblemType for HTTP 202 Accepted
- Added ProblemType for HTTP 203 Non-Authoritative Information
- Added ProblemType for HTTP 204 No Content
- Added ProblemType for HTTP 205 Reset Content
- Added ProblemType for HTTP 206 Partial Content
- Added ProblemType for HTTP 300 Multiple Choices
- Added ProblemType for HTTP 301 Moved Permanently
- Added ProblemType for HTTP 302 Found
- Added ProblemType for HTTP 303 See Other
- Added ProblemType for HTTP 304 Not Modified
- Added ProblemType for HTTP 305 Use Proxy
- Added ProblemType for HTTP 307 Temporary Redirect
- Added ProblemType for HTTP 308 Permanent Redirect
- Added ProblemType for HTTP 400 Bad Request
- Added ProblemType for HTTP 401 Unauthorized
- Added ProblemType for HTTP 403 Forbidden
- Added ProblemType for HTTP 404 Not Found
- Added ProblemType for HTTP 405 Method Not Allowed
- Added ProblemType for HTTP 406 Not Acceptable
- Added ProblemType for HTTP 409 Conflict
- Added ProblemType for HTTP 410 Gone
- Added ProblemType for HTTP 422 Unprocessable Entity
- Added ProblemType for HTTP 500 Internal Server Error
- Added ProblemType for HTTP 501 Not Implemented
- Added ProblemType for HTTP 502 Bad Gateway
- Added ProblemType for HTTP 503 Service Unavailable
- Added ProblemType for HTTP 504 Gateway Timeout
- Added ProblemType for HTTP 505 HTTP Version Not Supported
…blemtype.go`.

- Updated `ProblemDetails` methods for creating instances in `problemdetails.go`.
- Added unit tests for `ProblemDetails` creation functions in `problemdetails_test.go`.
- Defined `ProblemType` struct and various HTTP problem types in `problemtype.go`.
- Updated `ProblemDetails` methods for creating instances in `problemdetails.go`.
- Added unit tests for `ProblemDetails` creation functions in `problemdetails_test.go`.
- Added examples to `internal/examples`
- Updated README.md
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Welcome to the project! Verify your commit history (git log) to ensure it does NOT contain public email addresses!

Copy link
Member

@stevensefton stevensefton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See inline comment

Added test functions for methods with additional details and extensions:
- TestNewWithDetail
- TestNewWithExtension
- Added example of output in README.md
stevensefton
stevensefton previously approved these changes Oct 15, 2024
- Updated date on CHANGELOG.md
- Updated README.md to remove 'JSONJSON'
- Updated README.md to remove 'JSONJSON'
neiljpowell
neiljpowell previously approved these changes Oct 15, 2024
@shelleeboo shelleeboo merged commit 10a8c37 into main Oct 15, 2024
2 checks passed
@shelleeboo shelleeboo deleted the initial branch October 15, 2024 20:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants