-
Notifications
You must be signed in to change notification settings - Fork 0
Increase tests for requests #10
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
Merged
Merged
Changes from all commits
Commits
Show all changes
30 commits
Select commit
Hold shift + click to select a range
b03077b
refactor: decouple writer in requests printing functions
xenOs76 ab47545
refactor: decouple enable flag and header generation for SetProxyProt…
xenOs76 c447ab5
refactor: PrintCmd function call in requests_handlers
xenOs76 6080649
ci: add some tests for requests
xenOs76 c562210
fix: non-TLS test case out of main loop in TestPrintResponseDebug
xenOs76 101de86
refactor: check nil http Response in PrintResponseDebug
xenOs76 cb65898
refactor: manage error in PrintRequestDebug call
xenOs76 7eccb1b
fix: typo in TestNewHTTPClientFromRequestConfig
xenOs76 6c67a1d
refactor: TestPrintRespondeDebug to decrease assert check over partia…
xenOs76 97b2229
fix: typos in TestPrintRequestDebug
xenOs76 0c05e61
refactor: SetServerName check for empty string and url as input
xenOs76 3e31574
refactor: tests related to SetServerName
xenOs76 15b1478
fix: typos in tests
xenOs76 93bcea6
refactor: TestPrintCmd to check for partial string match
xenOs76 7035520
refactor: remove unused error retuened by SetProxyProtocolV2
xenOs76 3f7bfa4
fix: error checking and typos
xenOs76 40358d3
ci: add go code checks to GitHub Actions
xenOs76 beaca2d
ci: update checkout and Setup Go actions
xenOs76 9c4eb6d
fix: error assertion in SetClientTimeout test
xenOs76 23d605b
ci: wrap go-version in release action and update go.mod
xenOs76 463ba58
refactor: error handling
xenOs76 e20fa09
refactor: validate transportAddress value returned by RequestConfig H…
xenOs76 e3f9841
refactor: validate on empty byte list instead of comparing when Print…
xenOs76 0e46054
refactor: update test struct to manage cases causing errors
xenOs76 d4203ab
refactor: test loops using t.Parallel() to import a local copy of the…
xenOs76 b5a27a7
ci: test errors in PrintResponseDebug
xenOs76 e9b5db3
refactor: replace assert with require in SetInsecureSkipVerify
xenOs76 de18e71
ci: test malformed HTTP client in SetServerName
xenOs76 969f42b
ci: add tests to check nil or incomplete HTTP client in RequestHTTPCl…
xenOs76 cdf659e
refactor: require no error in SetClientTimeout
xenOs76 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,42 @@ | ||
| --- | ||
| name: code checks | ||
| on: | ||
| push: | ||
| paths: | ||
| - "cmd/**" | ||
| - "internal/**" | ||
| - "pkg/**" | ||
| - "*.go" | ||
| - "go.*" | ||
| jobs: | ||
| code_check_job: | ||
|
|
||
| runs-on: ubuntu-latest | ||
| strategy: | ||
| matrix: | ||
| go-version: ['1.24', '1.25'] | ||
|
|
||
| steps: | ||
| - name: Checkout | ||
| uses: actions/checkout@v5 | ||
|
|
||
| - name: Setup Go | ||
| uses: actions/setup-go@v6 | ||
| with: | ||
| go-version: ${{ matrix.go-version }} | ||
|
|
||
| - name: Install dependencies | ||
| run: go get . | ||
|
|
||
| - name: Build | ||
| run: go build -v ./... | ||
|
|
||
| - name: Test with the Go CLI | ||
| run: go test -v ./... | ||
|
|
||
| - name: Check for vulnerabilities | ||
| uses: golang/govulncheck-action@v1 | ||
| with: | ||
| go-version-input: ${{ matrix.go-version }} | ||
| go-package: ./... | ||
| work-dir: . |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,6 +1,6 @@ | ||
| module github.com/xenos76/https-wrench | ||
|
|
||
| go 1.24.4 | ||
| go 1.24.9 | ||
|
|
||
| require ( | ||
| github.com/alecthomas/assert/v2 v2.11.0 | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.