summaryrefslogtreecommitdiff
path: root/source4/torture
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2005-07-01 11:50:30 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:19:03 -0500
commit361d126d01d45053beb2582e01bc9e1fff6ad3db (patch)
tree4cbbd2deff48670b18b744e042795df1fea3acc6 /source4/torture
parent88df3c81ee283819faed2d521e98b1922c03854d (diff)
downloadsamba-361d126d01d45053beb2582e01bc9e1fff6ad3db.tar.gz
samba-361d126d01d45053beb2582e01bc9e1fff6ad3db.tar.bz2
samba-361d126d01d45053beb2582e01bc9e1fff6ad3db.zip
r8051: separate out the MAX EAs test, as it fills disk too much to be run regularly
(This used to be commit dac526845ea89ba732300105b3f82210b0828102)
Diffstat (limited to 'source4/torture')
-rw-r--r--source4/torture/raw/eas.c31
-rw-r--r--source4/torture/torture.c1
2 files changed, 30 insertions, 2 deletions
diff --git a/source4/torture/raw/eas.c b/source4/torture/raw/eas.c
index cbe89926da..1fec54b38a 100644
--- a/source4/torture/raw/eas.c
+++ b/source4/torture/raw/eas.c
@@ -35,7 +35,7 @@
goto done; \
}} while (0)
-static BOOL maxeadebug = 0; /* need that here, to allow no file delete in debug case */
+static BOOL maxeadebug; /* need that here, to allow no file delete in debug case */
static BOOL check_ea(struct smbcli_state *cli,
const char *fname, const char *eaname, const char *value)
@@ -460,11 +460,38 @@ BOOL torture_raw_eas(void)
return False;
}
- ret &= test_max_eas(cli, mem_ctx);
ret &= test_eas(cli, mem_ctx);
ret &= test_nttrans_create(cli, mem_ctx);
smb_raw_exit(cli->session);
+
+ torture_close_connection(cli);
+ talloc_free(mem_ctx);
+ return ret;
+}
+
+/*
+ test max EA size
+*/
+BOOL torture_max_eas(void)
+{
+ struct smbcli_state *cli;
+ BOOL ret = True;
+ TALLOC_CTX *mem_ctx;
+
+ if (!torture_open_connection(&cli)) {
+ return False;
+ }
+
+ mem_ctx = talloc_init("torture_raw_eas");
+
+ if (!torture_setup_dir(cli, BASEDIR)) {
+ return False;
+ }
+
+ ret &= test_max_eas(cli, mem_ctx);
+
+ smb_raw_exit(cli->session);
if (!maxeadebug) {
/* in no ea debug case, all files are gone now */
smbcli_deltree(cli->tree, BASEDIR);
diff --git a/source4/torture/torture.c b/source4/torture/torture.c
index 2cb9a22bcb..5fe8a9865d 100644
--- a/source4/torture/torture.c
+++ b/source4/torture/torture.c
@@ -2264,6 +2264,7 @@ static struct {
{"RAW-RENAME", torture_raw_rename, 0},
{"RAW-SEEK", torture_raw_seek, 0},
{"RAW-EAS", torture_raw_eas, 0},
+ {"RAW-EAMAX", torture_max_eas, 0},
{"RAW-STREAMS", torture_raw_streams, 0},
{"RAW-ACLS", torture_raw_acls, 0},
{"RAW-RAP", torture_raw_rap, 0},