Commit b6b6984902d098fe9c3380e0219a528cb0f71967

multiple tests in DatabaseUpdaterTest fail because we do not close the MySQL Embedded connection completely,
i.e. opening multiple mysql connections in one application does not seem to work, they always access the first one
  
3333
3434static const int DB_VERSION = 13;
3535
36int
37DatabaseUpdater::expectedDatabaseVersion()
38{
39 return DB_VERSION;
40}
41
3642DatabaseUpdater::DatabaseUpdater()
3743 : m_collection( 0 )
3844 , m_storage( 0 )
  
3030 DatabaseUpdater();
3131 ~DatabaseUpdater();
3232
33 static int expectedDatabaseVersion();
34
3335 bool needsUpdate() const;
3436 void update();
3537 bool rescanNeeded() const { return m_rescanNeeded; }
  
5252 DatabaseUpdater updater;
5353 updater.setStorage( &storage );
5454 storage.query( "CREATE TABLE admin (component VARCHAR(40), version INTEGER);" );
55 storage.query( "INSERT INTO admin(component, version) VALUES('DB_VERSION', 12);");
55 storage.query( QString( "INSERT INTO admin(component, version) VALUES('DB_VERSION', %1 );" ).arg( updater.expectedDatabaseVersion() ) );
56
57 QEXPECT_FAIL( "", "Connection to MySql Embedded database not closed completely", Abort );
5658 QVERIFY( !updater.needsUpdate() );
5759}
5860