Author: [EMAIL PROTECTED]
Date: Thu Nov 27 08:16:17 2008
New Revision: 2851
Modified:
trunk/regress/ca/sqlpower/architect/TestSQLDatabase.java
trunk/regress/ca/sqlpower/architect/swingui/TestingArchitectSwingSession.java
Log:
The order in which some of the fields in the TestingArchitectSwingSession
were being initialized was causing NPEs due to changes with ExportDDLAction
(initialization of the GUI components were moved into the constructor
rather than the actionPerformed method).
Also, TestSQLDatabase's test for the getName method needed to be modified
to account for changes in the getName method behaviour.
Modified: trunk/regress/ca/sqlpower/architect/TestSQLDatabase.java
==============================================================================
--- trunk/regress/ca/sqlpower/architect/TestSQLDatabase.java (original)
+++ trunk/regress/ca/sqlpower/architect/TestSQLDatabase.java Thu Nov 27
08:16:17 2008
@@ -125,6 +125,7 @@
*/
public void testGetName() {
SQLDatabase db1 = new SQLDatabase();
+ db1.setPlayPenDatabase(true);
assertEquals("PlayPen Database", db1.getName());
assertEquals("PlayPen Database", db1.getShortDisplayName());
assertEquals(db1.getName(), db1.getPhysicalName());
Modified:
trunk/regress/ca/sqlpower/architect/swingui/TestingArchitectSwingSession.java
==============================================================================
---
trunk/regress/ca/sqlpower/architect/swingui/TestingArchitectSwingSession.java
(original)
+++
trunk/regress/ca/sqlpower/architect/swingui/TestingArchitectSwingSession.java
Thu Nov 27 08:16:17 2008
@@ -101,14 +101,15 @@
compareDMSettings = new CompareDMSettings();
- frame = new ArchitectFrame(this, null);
- frame.init();
-
try {
ddlGenerator = new GenericDDLGenerator();
} catch (SQLException e) {
throw new ArchitectException("SQL Error in ddlGenerator",e);
}
+
+ frame = new ArchitectFrame(this, null);
+ frame.init();
+
kettleJob = new KettleJob(this);
}