From 36c884c8996cf860dcfcd66cd1ce137ff7acb4ee Mon Sep 17 00:00:00 2001 From: Peter Hormanns Date: Fri, 6 May 2011 15:51:37 +0000 Subject: [PATCH] work on tests --- hsarback/test/de/hsadmin/remote/MysqlUserTest.java | 13 +++++++------ hsarback/test/de/hsadmin/remote/PgsqlUserTest.java | 3 ++- hsarback/test/de/hsadmin/remote/RemoteTest.java | 8 ++++---- 3 files changed, 13 insertions(+), 11 deletions(-) diff --git a/hsarback/test/de/hsadmin/remote/MysqlUserTest.java b/hsarback/test/de/hsadmin/remote/MysqlUserTest.java index eacbaf2..065437d 100644 --- a/hsarback/test/de/hsadmin/remote/MysqlUserTest.java +++ b/hsarback/test/de/hsadmin/remote/MysqlUserTest.java @@ -12,6 +12,7 @@ import org.apache.xmlrpc.XmlRpcException; import org.apache.xmlrpc.client.XmlRpcClient; import org.junit.After; import org.junit.Before; +import org.junit.Ignore; import org.junit.Test; public class MysqlUserTest { @@ -35,7 +36,7 @@ public class MysqlUserTest { @Test public void testCreate() { - int count = getDBsCount(); + int count = getDBUsersCount(); String user = "aaa00"; String grantingTicketURL = cas.getGrantingTicketURL(user); Map setParams = new HashMap(); @@ -50,7 +51,7 @@ public class MysqlUserTest { } catch (XmlRpcException e) { fail(e.getMessage()); } - assertEquals(count + 1, getDBsCount()); + assertEquals(count + 1, getDBUsersCount()); } @Test @@ -70,9 +71,9 @@ public class MysqlUserTest { } } - @Test + @Test @Ignore public void testDelete() { - int count = getDBsCount(); + int count = getDBUsersCount(); String user = "aaa00"; String grantingTicketURL = cas.getGrantingTicketURL(user); Map whereParams = new HashMap(); @@ -86,10 +87,10 @@ public class MysqlUserTest { } catch (XmlRpcException e) { fail(e.getMessage()); } - assertEquals(count - 1, getDBsCount()); + assertEquals(count - 1, getDBUsersCount()); } - private int getDBsCount() { + private int getDBUsersCount() { int count = 0; String user = "aaa00"; String grantingTicketURL = cas.getGrantingTicketURL(user); diff --git a/hsarback/test/de/hsadmin/remote/PgsqlUserTest.java b/hsarback/test/de/hsadmin/remote/PgsqlUserTest.java index 66cdb4c..43e13de 100644 --- a/hsarback/test/de/hsadmin/remote/PgsqlUserTest.java +++ b/hsarback/test/de/hsadmin/remote/PgsqlUserTest.java @@ -12,6 +12,7 @@ import org.apache.xmlrpc.XmlRpcException; import org.apache.xmlrpc.client.XmlRpcClient; import org.junit.After; import org.junit.Before; +import org.junit.Ignore; import org.junit.Test; public class PgsqlUserTest { @@ -70,7 +71,7 @@ public class PgsqlUserTest { } } - @Test + @Test @Ignore public void testDelete() { int count = getDBsCount(); String user = "aaa00"; diff --git a/hsarback/test/de/hsadmin/remote/RemoteTest.java b/hsarback/test/de/hsadmin/remote/RemoteTest.java index 3f88d20..adcab36 100644 --- a/hsarback/test/de/hsadmin/remote/RemoteTest.java +++ b/hsarback/test/de/hsadmin/remote/RemoteTest.java @@ -8,11 +8,11 @@ import org.junit.runners.Suite; InitDataTest.class, PacTest.class, UnixUserTest.class, + MysqlUserTest.class, + MysqlDbTest.class, + PgsqlUserTest.class, + PgsqlDbTest.class, CustomerTest.class -// MysqlDbTest.class, -// MysqlUserTest.class, -// PgsqlDbTest.class, -// PgsqlUserTest.class, // EMailAliasTest.class, // EMailAddressTest.class, // DomainTest.class,