transfersh
The atago project wrote these specs on its own initiative and runs them in its own CI, to exercise atago against a real program. They are not transfersh’s official test suite, and the transfersh project is not affiliated with atago.
Summary #
1 suite · 3 scenarios
Contents #
- transfer.sh (self-hosted file sharing) — 3 scenarios
transfer.sh (self-hosted file sharing) #
Source: test/e2e/thirdparty/transfersh/transfersh.atago.yaml
Scenario: the binary reports its version #
When #
transfer.sh version
Then #
- exit code is
0 - stdout contains
transfer.sh
Scenario: a binary upload round-trips byte-for-byte #
Given #
- Background service
transfershis started:transfer.sh --provider local --basedir storage --temp-path tmp --listener 127.0.0.1:18210. - Fixture file
storage/.keepis created. - Fixture file
tmp/.keepis created. - Fixture file
pixel.pngis created.
When #
# HTTP PUT /pixel.png
# capture ${share_url} from the response body
# HTTP GET ${share_url}
cmp pixel.png downloaded.png
Then #
- after
HTTP PUT /pixel.png:- HTTP status is
200 - body contains
http://127.0.0.1:18210/
- HTTP status is
- after
HTTP GET ${share_url}:- HTTP status is
200 - image
downloaded.pngispng, width 1, height 1
- HTTP status is
- after
cmp pixel.png downloaded.png:- exit code is
0
- exit code is
Generated artifacts #
downloaded.png
Scenario: a browser-style multipart upload is accepted too #
Given #
- Background service
transfershis started:transfer.sh --provider local --basedir storage --temp-path tmp --listener 127.0.0.1:18211. - Fixture file
storage/.keepis created. - Fixture file
tmp/.keepis created. - Fixture file
notes.txtis created.
Inputs #
Fixture notes.txt:
shared through a multipart form
When #
# HTTP POST /
# capture ${share_url} from the response body
# HTTP GET ${share_url}
# HTTP GET /no-such-token/notes.txt
Then #
- after
HTTP POST /:- HTTP status is
200 - body contains
http://127.0.0.1:18211/
- HTTP status is
- after
HTTP GET ${share_url}:- HTTP status is
200 - body contains
shared through a multipart form
- HTTP status is
- after
HTTP GET /no-such-token/notes.txt:- HTTP status is
404
- HTTP status is