public class AlternateUsernameTest extends DefaultTestCase {
- private static final int iterations = (new Random(System.currentTimeMillis())).nextInt(10000000)+100000;
+ private static final int iterations = (new Random(System.currentTimeMillis())).nextInt(1000000)+100000;
public AlternateUsernameTest(String name) {
super(name);
}
- public void testGeneric() throws Exception {
+ public void testUsernameCompare() throws Exception {
this.init();
this.datasource.setDriverClassName(Driver.class.getName());
}
+ public void testUsernameCompareAgain() throws Exception {
+ testUsernameCompare();
+ }
+
public static class TestResult {
public int iterations;
public int failures;
}
public boolean acceptsURL(String url) throws SQLException {
- return url == Driver.url;
+ return url!=null && url.equals(Driver.url);
}
public Connection connect(String url, Properties info) throws SQLException {