Last night, I gave a presentation at the Greater Boston Selenium User Group. The title of my presentation was “def test = new BDDMadeEasy(Selenium,EasyB,Groovy)“.

It was fun . Enjoyed interacting with fellow Selenium enthusiasts. Excellent questions.  Hopefully got some people excited to give BDD a try.

You can view the slides at slideshare.

And you can also download the sample code that I wrote\showed along with my presentation from here.

And some links to reading material on BDD\Selenium.

If you attended the meeting , and have more specific questions- please leave a comment or you can find many ways to contact me via my website or leave a message and I will email you back.

And oh yes-  Thanks Ashish, glad you found it useful .

 

The context

I am using Google App Engine using the  Grails AppEngine plugin . The default port is 8080, but I needed to run it on a different port.

It was easy to figure out that Google App Engine supports running the development server on any configured port. But it took me some time to realize that the  Grails AppEngine plugin that I am using doesn’t.

The fix:

Modify the \plugins\app-engine-0.8.5\scripts\AppEngine.groovy.

Continue reading »

 

Grails quick-start example is a neat way to start off with Grails.

It will show you how to connect to HSQLDB and gets a quick and elementary web app up and running in no time.

But soon, I wanted to get on with the “real” stuff- Oracle

These are the changes I did to connect with Oracle (and errors I encountered on the way).

But first the Version disclaimer

Groovy:1.6.2

Grails: 1.1

Oracle::9.2.0.6.0
A) Changed the DataSource.groovy as follows

dataSource {
pooled = true
driverClassName = “oracle.jdbc.driver.OracleDriver”
username = “user”
password = “password”
dialect=’org.hibernate.dialect.Oracle9Dialect’

}

environments {
development {
dataSource {
dbCreate = “create-drop” // one of ‘create’, ‘create-drop’,'update’
url = “jdbc:oracle:thin:@myservername:1521:mysid”
}
}
// Left test and Production as they were….

}
B) Dropped the oracle driver jar file in the lib folder under the grails- app folder

Bingo !!! That’s it !!!

I got only one error-  (see at the end of this post) And this maybe specific to Oracle 9i.

The fix was to add this line to the  data source.groovy

dialect=’org.hibernate.dialect.Oracle9Dialect’

(If you are using a higher version of Oracle- you may need to use a different Dialect)

Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘dialectDetector’: Invocation of init method failed; nested exception is org.springframework.jdbc.support.MetaDataAccessException: Error while extracting DatabaseMetaData; nested exception is java.sql.SQLException: Unsupported feature
at java.security.AccessController.doPrivileged(Native Method)
… 24 more
Caused by: org.springframework.jdbc.support.MetaDataAccessException: Error while extracting DatabaseMetaData; nested exception is java.sql.SQLException: Unsupported feature
… 25 more
Caused by: java.sql.SQLException: Unsupported feature
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:179)
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:269)
at oracle.jdbc.dbaccess.DBError.throwUnsupportedFeatureSqlException(DBError.java:689)
at oracle.jdbc.OracleDatabaseMetaData.getDatabaseMajorVersion(OracleDatabaseMetaData.java:4442)
… 25 more
2009-04-27 10:57:39,450 [main] ERROR mortbay.log  – Failed startup of context

© 2011 Technology Cafe Suffusion theme by Sayontan Sinha