Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them. Page: /drakestapleton/omega-feel/blob/main/tests/seal.sh # omega-feel This project has not described itself yet. Brought by drakestapleton Sign in to star 0 stars 0 watching About Files History Releases Proposed changes Issues For developers branch `main` Branches Tags History `omega-feel / tests / seal.sh` 13 lines ยท 951 bytes Raw Blame History 1 #!/bin/sh 2 # tests/seal.sh: write tests/wolfram.sha256, one line per Wolfram script: its name, its SHA-256, the file 3 # holding its result and that file's SHA-256. The result of oracle.wl is expected-wolfram.txt; the result 4 # of every other NAME.wl is NAME-result.txt. Run it after a script has been evaluated and its final value 5 # written to the result file; tests/run.sh then fails when a script or a result changes without the 6 # other being evaluated and sealed again. It records what is on disk. It does not run Wolfram, so it 7 # cannot show that a result came from its script: a second evaluation by someone else does that. 8 cd "$(dirname "$0")" || exit 1 9 for w in *.wl; do 10 case $w in oracle.wl) r=expected-wolfram.txt ;; *) r=${w%.wl}-result.txt ;; esac 11 [ -f "$r" ] || { echo "seal: no $r for $w" >&2; exit 1; } 12 printf '%s %s %s %s\n' "$w" "$(sha256sum < "$w" | cut -d' ' -f1)" "$r" "$(sha256sum < "$r" | cut -d' ' -f1)" 13 done > wolfram.sha256