Revision: 6301
http://squirrel-sql.svn.sourceforge.net/squirrel-sql/?rev=6301&view=rev
Author: manningr
Date: 2011-06-08 11:18:35 +0000 (Wed, 08 Jun 2011)
Log Message:
-----------
More tests for proper identification of Dialects. Still more to come.
Modified Paths:
--------------
trunk/sql12/fw/src/test/java/net/sourceforge/squirrel_sql/fw/dialects/DialectFactoryTest.java
Modified: trunk/sql12/fw/src/test/java/net/sourceforge/squirrel_sql/fw/dialects/DialectFactoryTest.java
===================================================================
--- trunk/sql12/fw/src/test/java/net/sourceforge/squirrel_sql/fw/dialects/DialectFactoryTest.java 2011-06-08 03:05:54 UTC (rev 6300)
+++ trunk/sql12/fw/src/test/java/net/sourceforge/squirrel_sql/fw/dialects/DialectFactoryTest.java 2011-06-08 11:18:35 UTC (rev 6301)
@@ -69,6 +69,18 @@
private static final String INGRES_PRODUCT_VERSION = "II 9.1.1 (int.rpl/103)";
+ private static final String MSSQL_PRODUCT_NAME = "Microsoft SQL Server";
+
+ private static final String MSSQL_PRODUCT_VERSION = "9.00.3077";
+
+ private static final String MYSQL_PRODUCT_NAME = "MySQL";
+
+ private static final String MYSQL_PRODUCT_VERSION = "4.1.22-standard";
+
+ private static final String MYSQL5_PRODUCT_NAME = "MySQL";
+
+ private static final String MYSQL5_PRODUCT_VERSION = "5.1.41-3ubuntu12.10";
+
private static final String POSTGRESQL_PRODUCT_NAME = "PostgreSQL";
private static final String POSTGRESQL_PRODUCT_VERSION = "8.3.1";
@@ -359,8 +371,35 @@
final String expectedDialectClassname = IngresDialectExt.class.getName();
testGetDialectForDatabase(productName, productVersion, expectedDialectClassname);
}
+
+ @Test
+ public void testGetDialectForMssql() throws SQLException
+ {
+ final String productName = MSSQL_PRODUCT_NAME;
+ final String productVersion = MSSQL_PRODUCT_VERSION;
+ final String expectedDialectClassname = SQLServerDialectExt.class.getName();
+ testGetDialectForDatabase(productName, productVersion, expectedDialectClassname);
+ }
+
+ @Test
+ public void testGetDialectForMysql() throws SQLException
+ {
+ final String productName = MYSQL_PRODUCT_NAME;
+ final String productVersion = MYSQL_PRODUCT_VERSION;
+ final String expectedDialectClassname = MySQLDialectExt.class.getName();
+ testGetDialectForDatabase(productName, productVersion, expectedDialectClassname);
+ }
@Test
+ public void testGetDialectForMysql5() throws SQLException
+ {
+ final String productName = MYSQL5_PRODUCT_NAME;
+ final String productVersion = MYSQL5_PRODUCT_VERSION;
+ final String expectedDialectClassname = MySQL5DialectExt.class.getName();
+ testGetDialectForDatabase(productName, productVersion, expectedDialectClassname);
+ }
+
+ @Test
public void testGetDialectForPostgreSQL() throws SQLException
{
final String productName = POSTGRESQL_PRODUCT_NAME;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|