summaryrefslogtreecommitdiff
path: root/source4/torture/basic
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2004-12-31 08:44:08 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:07:51 -0500
commit13f47df8cd22f48b348d5a22f2510c7f6e700001 (patch)
treece88fa9a1af73dc2a92bbcae545338a9490ad52b /source4/torture/basic
parentf1938123a613ac81f11b00ff5876a7cc71168cfb (diff)
downloadsamba-13f47df8cd22f48b348d5a22f2510c7f6e700001.tar.gz
samba-13f47df8cd22f48b348d5a22f2510c7f6e700001.tar.bz2
samba-13f47df8cd22f48b348d5a22f2510c7f6e700001.zip
r4445: put the unlink test in a subdirectory, and ensure it cleans up
(This used to be commit 382231ca365eccec8024af9420b1ebe41953bdb5)
Diffstat (limited to 'source4/torture/basic')
-rw-r--r--source4/torture/basic/unlink.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/source4/torture/basic/unlink.c b/source4/torture/basic/unlink.c
index 75d1549fcf..30d862e345 100644
--- a/source4/torture/basic/unlink.c
+++ b/source4/torture/basic/unlink.c
@@ -24,6 +24,8 @@
#include "libcli/raw/libcliraw.h"
#include "librpc/gen_ndr/ndr_security.h"
+#define BASEDIR "\\unlinktest"
+
/*
This test checks that
@@ -32,7 +34,7 @@
BOOL torture_unlinktest(void)
{
struct smbcli_state *cli;
- const char *fname = "\\unlink.tst";
+ const char *fname = BASEDIR "\\unlink.tst";
int fnum;
BOOL correct = True;
union smb_open io;
@@ -44,7 +46,9 @@ BOOL torture_unlinktest(void)
printf("starting unlink test\n");
- smbcli_unlink(cli->tree, fname);
+ if (!torture_setup_dir(cli, BASEDIR)) {
+ return False;
+ }
cli->session->pid = 1;