aboutsummaryrefslogtreecommitdiffstats
path: root/tests/fixtures
diff options
context:
space:
mode:
authorMartin Czygan <martin.czygan@gmail.com>2020-11-24 15:51:03 +0100
committerMartin Czygan <martin.czygan@gmail.com>2020-11-24 15:51:03 +0100
commit57d68f5bffecd2beace5af5fd6478480e5033b92 (patch)
tree6919241f53f06ccef27663ed05ae4277da14166c /tests/fixtures
parent81e27247a484c2613e245126c06605052bafa3b6 (diff)
downloadfuzzycat-57d68f5bffecd2beace5af5fd6478480e5033b92.tar.gz
fuzzycat-57d68f5bffecd2beace5af5fd6478480e5033b92.zip
script logging and atomic download
Diffstat (limited to 'tests/fixtures')
-rwxr-xr-xtests/fixtures/verify-entity-download.sh3
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/fixtures/verify-entity-download.sh b/tests/fixtures/verify-entity-download.sh
index 790afa0..bc229bf 100755
--- a/tests/fixtures/verify-entity-download.sh
+++ b/tests/fixtures/verify-entity-download.sh
@@ -13,5 +13,6 @@ for ident in $(awk -F, '{print $1"\n"$2}' "$CSV"); do
>&2 echo "[cached] $ident"
continue
fi
- curl -sL --fail "$API/release/$ident" | jq --sort-keys . >"$ident"
+ tempfile=$(mktemp)
+ curl -sL --fail "$API/release/$ident" | jq --sort-keys . > "$tempfile" && mv "$tempfile" "$ident"
done