13af2af2518dc5534c94285e77d39d0fc729ed917Andy Hung#!/bin/bash
23af2af2518dc5534c94285e77d39d0fc729ed917Andy Hung#
33af2af2518dc5534c94285e77d39d0fc729ed917Andy Hung# Run tests in this directory.
43af2af2518dc5534c94285e77d39d0fc729ed917Andy Hung#
53af2af2518dc5534c94285e77d39d0fc729ed917Andy Hung
63af2af2518dc5534c94285e77d39d0fc729ed917Andy Hungif [ -z "$ANDROID_BUILD_TOP" ]; then
73af2af2518dc5534c94285e77d39d0fc729ed917Andy Hung    echo "Android build environment not set"
83af2af2518dc5534c94285e77d39d0fc729ed917Andy Hung    exit -1
93af2af2518dc5534c94285e77d39d0fc729ed917Andy Hungfi
103af2af2518dc5534c94285e77d39d0fc729ed917Andy Hung
113af2af2518dc5534c94285e77d39d0fc729ed917Andy Hung# ensure we have mm
123af2af2518dc5534c94285e77d39d0fc729ed917Andy Hung. $ANDROID_BUILD_TOP/build/envsetup.sh
133af2af2518dc5534c94285e77d39d0fc729ed917Andy Hung
143af2af2518dc5534c94285e77d39d0fc729ed917Andy Hungmm
153af2af2518dc5534c94285e77d39d0fc729ed917Andy Hung
163af2af2518dc5534c94285e77d39d0fc729ed917Andy Hungecho "waiting for device"
173af2af2518dc5534c94285e77d39d0fc729ed917Andy Hung
183af2af2518dc5534c94285e77d39d0fc729ed917Andy Hungadb root && adb wait-for-device remount
193af2af2518dc5534c94285e77d39d0fc729ed917Andy Hung
203af2af2518dc5534c94285e77d39d0fc729ed917Andy Hungecho "========================================"
213af2af2518dc5534c94285e77d39d0fc729ed917Andy Hungecho "testing primitives"
223af2af2518dc5534c94285e77d39d0fc729ed917Andy Hungadb push $OUT/system/lib/libaudioutils.so /system/lib
233af2af2518dc5534c94285e77d39d0fc729ed917Andy Hungadb push $OUT/system/bin/primitives_tests /system/bin
243af2af2518dc5534c94285e77d39d0fc729ed917Andy Hungadb shell /system/bin/primitives_tests
25