summaryrefslogtreecommitdiff
path: root/tests/cli-opts.sh
diff options
context:
space:
mode:
authorEuAndreh <eu@euandre.org>2026-02-28 11:39:42 -0300
committerEuAndreh <eu@euandre.org>2026-02-28 11:39:44 -0300
commitf691d7cdb45477fe2eba0689f054035ec68cac25 (patch)
tree2b55a14336c340d380e7a60d97da4c4c427572f4 /tests/cli-opts.sh
parentMakefile: Add switch for picking number of parallel fuzz workers (diff)
downloadscrypt-f691d7cdb45477fe2eba0689f054035ec68cac25.tar.gz
scrypt-f691d7cdb45477fe2eba0689f054035ec68cac25.tar.xz
src/scrypt.go: Get password and salt from stdinHEADmain
Instead of passing the password and salt as arguments to the command, read it from stdin instead, as the argument to a process are visible to all other processes.
Diffstat (limited to 'tests/cli-opts.sh')
-rwxr-xr-xtests/cli-opts.sh45
1 files changed, 0 insertions, 45 deletions
diff --git a/tests/cli-opts.sh b/tests/cli-opts.sh
index 4f59185..92b70ea 100755
--- a/tests/cli-opts.sh
+++ b/tests/cli-opts.sh
@@ -1,47 +1,2 @@
#!/bin/sh
set -eu
-
-. tests/lib.sh
-
-
-test_needs_2_arguments() {
- testing 'needs 2 arguments'
-
- N="$LINENO"
- OUT="$(mkstemp)"
- ERR="$(mkstemp)"
- trap 'rm -f "$OUT" "$ERR"' EXIT
- STATUS=0
- ./scrypt.bin 1>"$OUT" 2>"$ERR" || STATUS=$?
- assert_status 2
- assert_empty_stdout
- assert_usage "$ERR"
- rm -f "$OUT" "$ERR"
-
- N="$LINENO"
- OUT="$(mkstemp)"
- ERR="$(mkstemp)"
- trap 'rm -f "$OUT" "$ERR"' EXIT
- STATUS=0
- ./scrypt.bin password 1>"$OUT" 2>"$ERR" || STATUS=$?
- assert_status 2
- assert_empty_stdout
- assert_usage "$ERR"
- rm -f "$OUT" "$ERR"
-
- N="$LINENO"
- OUT="$(mkstemp)"
- ERR="$(mkstemp)"
- trap 'rm -f "$OUT" "$ERR"' EXIT
- STATUS=0
- ./scrypt.bin salt 1>"$OUT" 2>"$ERR" || STATUS=$?
- assert_status 2
- assert_empty_stdout
- assert_usage "$ERR"
- rm -f "$OUT" "$ERR"
-
- test_ok
-}
-
-
-test_needs_2_arguments