If integration tests pass on SQLite means they will always pass on MS SQL Server too?

4 views
Skip to first unread message

Michiel

unread,
Dec 2, 2008, 10:27:26 AM12/2/08
to nhusers
Hello,

I recently started to write integration tests for my repositories,
which are implemented using NHibernate 2.0. I use SQLite in memory
databases to run the tests in isolation (recreating the database for
each test). This is a convenient way to run integration tests because
it is pretty fast.

The application will ultimately run on MS SQL Server. Can I just
assume that when my integration tests pass that the tested code will
work on SQL Server as well? Or should I do integration tests on the
actual database type that the application will use?

Thank you!

Ayende Rahien

unread,
Dec 2, 2008, 10:44:27 AM12/2/08
to nhu...@googlegroups.com
No, you can't.
But you have very high assurance that they will be

paulh

unread,
Dec 2, 2008, 10:51:21 AM12/2/08
to nhu...@googlegroups.com
As Oren say you can't assume this, but a reasonable comprise might be to have two continuous integration processes - the one that runs on check in uses the SQLite database for the unit tests, but the nightly build is run against SQL Server.

This should give you a fast enough head-up if something goes wrong.

Paul


From: Michiel <michi...@gmail.com>
Sent: 02 December 2008 15:35
To: nhusers <nhu...@googlegroups.com>
Subject: [nhusers] If integration tests pass on SQLite means they will always pass on MS SQL Server too?

Stefan Steinegger

unread,
Dec 2, 2008, 11:10:47 AM12/2/08
to nhusers
For instance, we had issues with DateTime. SqlServer is limited in
range and does not store milliseconds, while Sqlite just worked fine.

Will Shaver

unread,
Dec 2, 2008, 12:09:42 PM12/2/08
to nhu...@googlegroups.com
I just (as in right now) wrote a big post on dealing with DateTime conversion for SQL Server. Moderately relavant to this discussion.
 
 -Will

Fabio Maulo

unread,
Dec 2, 2008, 12:26:08 PM12/2/08
to nhu...@googlegroups.com
2008/12/2 Will Shaver <will....@gmail.com>

I just (as in right now) wrote a big post on dealing with DateTime conversion for SQL Server. Moderately relavant to this discussion.

Will take a look on how use <typedef> if you often use your usertype.
--
Fabio Maulo

Will Shaver

unread,
Dec 2, 2008, 12:29:07 PM12/2/08
to nhu...@googlegroups.com

Thanks!

On Dec 2, 2008 9:26 AM, "Fabio Maulo" <fabio...@gmail.com> wrote:

2008/12/2 Will Shaver <will....@gmail.com>

> > I just (as in right now) wrote a big post on dealing with DateTime conversion for SQL Server. M...

Will take a look on how use <typedef> if you often use your usertype.

--
Fabio Maulo

--~--~---------~--~----~------------~-------~--~----~ You received this message because you are su...

Michiel

unread,
Dec 2, 2008, 4:19:01 PM12/2/08
to nhusers

Ok, I'll run it on SQL Server to be sure.

Thank you!

On Dec 2, 4:44 pm, "Ayende Rahien" <aye...@ayende.com> wrote:
> No, you can't.But you have very high assurance that they will be
Reply all
Reply to author
Forward
0 new messages