#!/system/bin/sh

. $UFA_DIR/ufa-test-functions

bbox="$UFA_DIR/busybox"

# Set up and clear the log file
log="$UFA_DATA_DIR/ufa-test-lxc-binaries.log"
>$log

BINS="lxc-start
lxc-stop
lxc-freeze
lxc-unfreeze
lxc-console
lxc-wait"

for bin in $BINS
do
    $bbox which $bin 2>&1 > /dev/null
    if [ $? -eq 0 ]; then
        log "PASS: $bin is present, in PATH, and executable" $log
        continue
    else
        log "FAIL: $bin is missing, not in PATH or not executable" $log
        continue
    fi
done
