mirror of
https://github.com/hsoft/collapseos.git
synced 2024-11-24 08:28:06 +11:00
e691dab070
Use IX directly for argspec rows instead of going through DE. It saves a bit of processing. The code was this way because I initially didn't use IX at all, so as code evolved, that DE translation stayed as an artifact.
30 lines
500 B
Bash
Executable File
30 lines
500 B
Bash
Executable File
#!/usr/bin/env bash
|
|
set -e
|
|
# TODO: find POSIX substitute to that PIPESTATUS thing
|
|
|
|
BASE=../../..
|
|
TOOLS=../..
|
|
ZASM="${TOOLS}/zasm.sh"
|
|
RUNBIN="${TOOLS}/emul/runbin/runbin"
|
|
KERNEL="${BASE}/kernel"
|
|
APPS="${BASE}/apps"
|
|
|
|
chk() {
|
|
echo "Running test $1"
|
|
if ! ${ZASM} "${KERNEL}" "${APPS}" < $1 | ${RUNBIN}; then
|
|
echo "failed with code ${PIPESTATUS[1]}"
|
|
exit 1
|
|
fi
|
|
}
|
|
|
|
if [ ! -z $1 ]; then
|
|
chk $1
|
|
exit 0
|
|
fi
|
|
|
|
for fn in *.asm; do
|
|
chk "${fn}"
|
|
done
|
|
|
|
echo "All tests passed!"
|