nvme: run unit tests under Valgrind if available
Change-Id: Iad8403903d420418692793d9940e33e2d3772e6b Signed-off-by: Daniel Verkamp <daniel.verkamp@intel.com>
This commit is contained in:
parent
1c96eff6a2
commit
8780063f2c
@ -8,6 +8,8 @@ out=$PWD
|
|||||||
MAKEFLAGS=${MAKEFLAGS:--j16}
|
MAKEFLAGS=${MAKEFLAGS:--j16}
|
||||||
DPDK_DIR=/usr/local/dpdk-2.1.0/x86_64-native-linuxapp-gcc
|
DPDK_DIR=/usr/local/dpdk-2.1.0/x86_64-native-linuxapp-gcc
|
||||||
|
|
||||||
|
umask 022
|
||||||
|
|
||||||
cd $src
|
cd $src
|
||||||
|
|
||||||
./scripts/check_format.sh
|
./scripts/check_format.sh
|
||||||
|
@ -7,6 +7,13 @@ else
|
|||||||
output_dir=$rootdir/../output
|
output_dir=$rootdir/../output
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if hash valgrind &> /dev/null; then
|
||||||
|
# TODO: add --error-exitcode=2 when all Valgrind warnings are fixed
|
||||||
|
valgrind='valgrind --leak-check=full'
|
||||||
|
else
|
||||||
|
valgrind=''
|
||||||
|
fi
|
||||||
|
|
||||||
function timing() {
|
function timing() {
|
||||||
direction="$1"
|
direction="$1"
|
||||||
testname="$2"
|
testname="$2"
|
||||||
|
@ -4,11 +4,11 @@ testdir=$(readlink -f $(dirname $0))
|
|||||||
rootdir="$testdir/../../.."
|
rootdir="$testdir/../../.."
|
||||||
source $rootdir/scripts/autotest_common.sh
|
source $rootdir/scripts/autotest_common.sh
|
||||||
|
|
||||||
$testdir/unit/nvme_ns_cmd_c/nvme_ns_cmd_ut
|
$valgrind $testdir/unit/nvme_ns_cmd_c/nvme_ns_cmd_ut
|
||||||
$testdir/unit/nvme_c/nvme_ut
|
$valgrind $testdir/unit/nvme_c/nvme_ut
|
||||||
$testdir/unit/nvme_qpair_c/nvme_qpair_ut
|
$valgrind $testdir/unit/nvme_qpair_c/nvme_qpair_ut
|
||||||
$testdir/unit/nvme_ctrlr_c/nvme_ctrlr_ut
|
$valgrind $testdir/unit/nvme_ctrlr_c/nvme_ctrlr_ut
|
||||||
$testdir/unit/nvme_ctrlr_cmd_c/nvme_ctrlr_cmd_ut
|
$valgrind $testdir/unit/nvme_ctrlr_cmd_c/nvme_ctrlr_cmd_ut
|
||||||
|
|
||||||
$testdir/aer/aer
|
$testdir/aer/aer
|
||||||
process_core
|
process_core
|
||||||
|
Loading…
Reference in New Issue
Block a user