From aa09d8a75f04dd2680aa7c0f06e47b6f5a36fa56 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Tue, 16 Sep 2008 18:16:49 +0200 Subject: Move ndrdump tests closer to the code they test. --- source4/librpc/tests/samr-CreateUser-in.dat | Bin 0 -> 60 bytes source4/librpc/tests/samr-CreateUser-out.dat | Bin 0 -> 32 bytes source4/librpc/tests/test_ndrdump.sh | 20 ++++++++++++++++++++ 3 files changed, 20 insertions(+) create mode 100644 source4/librpc/tests/samr-CreateUser-in.dat create mode 100644 source4/librpc/tests/samr-CreateUser-out.dat create mode 100755 source4/librpc/tests/test_ndrdump.sh (limited to 'source4/librpc/tests') diff --git a/source4/librpc/tests/samr-CreateUser-in.dat b/source4/librpc/tests/samr-CreateUser-in.dat new file mode 100644 index 0000000000..a5840e1f7f Binary files /dev/null and b/source4/librpc/tests/samr-CreateUser-in.dat differ diff --git a/source4/librpc/tests/samr-CreateUser-out.dat b/source4/librpc/tests/samr-CreateUser-out.dat new file mode 100644 index 0000000000..cf9131dba9 Binary files /dev/null and b/source4/librpc/tests/samr-CreateUser-out.dat differ diff --git a/source4/librpc/tests/test_ndrdump.sh b/source4/librpc/tests/test_ndrdump.sh new file mode 100755 index 0000000000..50fd76ba92 --- /dev/null +++ b/source4/librpc/tests/test_ndrdump.sh @@ -0,0 +1,20 @@ +#!/bin/sh +# Blackbox tests for masktest +# Copyright (C) 2008 Andrew Tridgell +# Copyright (C) 2008 Andrew Bartlett +# based on test_smbclient.sh + +. `dirname $0`/subunit.sh + +failed=0 + +samba4bindir=`dirname $0`/../../source4/bin +ndrdump=$samba4bindir/ndrdump +files=`dirname $0`/ndrdump + +testit "ndrdump with in" $VALGRIND $ndrdump samr samr_CreateUser in $files/samr-CreateUser-in.dat $@ || failed=`expr $failed + 1` +testit "ndrdump with out" $VALGRIND $ndrdump samr samr_CreateUser out $files/samr-CreateUser-out.dat $@ || failed=`expr $failed + 1` +testit "ndrdump with --context-file" $VALGRIND $ndrdump --context-file $files/samr-CreateUser-in.dat samr samr_CreateUser out $files/samr-CreateUser-out.dat $@ || failed=`expr $failed + 1` +testit "ndrdump with validate" $VALGRIND $ndrdump --validate samr samr_CreateUser in $files/samr-CreateUser-in.dat $@ || failed=`expr $failed + 1` + +exit $failed -- cgit From 3e5ba883b3dd82e5285d98b8c5083336c478ba04 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Tue, 16 Sep 2008 18:39:08 +0200 Subject: Fix paths to subunit.sh --- source4/librpc/tests/test_ndrdump.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source4/librpc/tests') diff --git a/source4/librpc/tests/test_ndrdump.sh b/source4/librpc/tests/test_ndrdump.sh index 50fd76ba92..dddfc0eae1 100755 --- a/source4/librpc/tests/test_ndrdump.sh +++ b/source4/librpc/tests/test_ndrdump.sh @@ -4,7 +4,7 @@ # Copyright (C) 2008 Andrew Bartlett # based on test_smbclient.sh -. `dirname $0`/subunit.sh +. `dirname $0`/../../../testprogs/blackbox/subunit.sh failed=0 -- cgit