-
Notifications
You must be signed in to change notification settings - Fork 483
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
handler: Simultaneous support for -01 and -02 of IETF draft (#1066)
* [ADD] support for both draft v01 and v02 for the upload protocol This improves commit 09f105d to support both draft v01 and draft v02 versions of the ietf upload protocol * [ADD] config.go allowheaders * [ADD] tests to cors head and post Patch coming next * [HF] minor be even more explicit on which version has which headers * [ADD] patch test works now * [REFACTOR] don't use slices since not supported Error: pkg/handler/unrouted_handler.go:12:2: package slices is not in GOROOT (/Users/runner/hostedtoolcache/go/1.20.12/x64/src/slices) * [FIX] easy comments * [HF] extract isDraftVersionResumableUploadComplete * [HF] more consistent naming * [HF slightly cleaner code * [HF] comments on functions * [HF] bad find and replace * [REFACTOR] deduplicate code on post_test.go * [REFACTOR] head_test to deduplicate code * [REFACTOR] patch test to not repeat itself + standardize post test with othes * Make interop versions unexported and add comment * Rename some function to be shorter and clearer * Update variable names for distinguishing them * Put setting of Upload-Complete into own function * Typo * Refactor HEAD tests * Refactor POST tests * Refactor PATCH test * Reuse test helper * Move setting of interop version out of unrelated function --------- Co-authored-by: Marius Kleidl <marius@transloadit.com>
- Loading branch information
1 parent
bbc40a9
commit 9801b91
Showing
7 changed files
with
488 additions
and
413 deletions.
There are no files selected for viewing
This file contains 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 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 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.