Initial commit
This commit is contained in:
28
test-bins/pr/test-get.sh
Executable file
28
test-bins/pr/test-get.sh
Executable file
@@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env bash
|
||||
workdir="$(mktemp -d)"
|
||||
|
||||
function finish {
|
||||
rm -rf "${workdir}"
|
||||
}
|
||||
trap finish EXIT
|
||||
|
||||
version="${version:=1}"
|
||||
|
||||
read -r -d '' payload <<EOF
|
||||
{
|
||||
"source": {
|
||||
"api_token": "",
|
||||
"repo": "test-repo",
|
||||
"owner": "${USER}",
|
||||
"hostname": "127.0.0.1",
|
||||
"port": "3000",
|
||||
"insecure": true,
|
||||
"skip_ssl_verification": true
|
||||
},
|
||||
"version": { "number": "${version}" }
|
||||
}
|
||||
EOF
|
||||
|
||||
go run main.go --action get pr --destination "${workdir}" <<< "${payload}"
|
||||
|
||||
cat "${workdir}"/*
|
Reference in New Issue
Block a user