Yeah, I already use it. But it is really only effectively used against  
a generated database ( freshly empty ) since the tests are not  
idempotent.

I tried wrapping the tests in a transaction that I always rolled back,  
but that didn't work.

I need either a test that just compares the schema or can be made  
idempotent if it does actual inserts.

On Mar 11, 2009, at 4:51 AM, James Gregory <jagregory....@gmail.com>  
wrote:

> Did you see my message? Have you tried the PersistenceSpecification?
>
> On Tue, Mar 10, 2009 at 1:55 PM, Brendan Erwin <brendanjer...@gmail.com 
> > wrote:
> Hmmm. I guess I imagined it. :)
>
> The issues I'm having are things like string truncation errors and  
> missing not nulls. Any ideas how I can get red/green testing to  
> prevent these sorts of runtime errors?
>       
>
> On Mar 10, 2009, at 7:47 AM, Martin Hornagold wrote:
>
>> S#arp Architecture users are using the simple sanity check from  
>> Ayende:
>>
>> http://ayende.com/Blog/archive/2006/08/09/NHibernateMappingCreatingSanityChecks.aspx
>>
>>
>> From: fluent-nhibernate@googlegroups.com 
>> [mailto:fluent-nhibernate@googlegroups.com 
>> ] On Behalf Of James Gregory
>> Sent: 10 March 2009 11:24
>> To: fluent-nhibernate@googlegroups.com
>> Subject: [fluent-nhib] Re: Testing against existing schema
>>
>> There's the PersistenceSpecification which will verify your  
>> mappings are persisted correctly. Most of the time we hook it up to  
>> a SQLite DB, but there's nothing stopping you from using it against  
>> another database. Should work for what you need. Just be warned it  
>> doesn't handle complex mappings very well, but it should be alright  
>> with the basics.
>>
>> On Tue, Mar 10, 2009 at 10:09 AM, Andrew Stewart <andrewnstew...@gmail.com 
>> > wrote:
>> Not to me sorry, anyone else know anything.
>>
>>
>> On Mon, Mar 9, 2009 at 6:07 PM, brendanjerwin <brendanjer...@gmail.com 
>> > wrote:
>>
>> I seem to remember reading something a while back about a tool in
>> fluent nhibernate (or near it) that would assist in testing that
>> mappings do not conflict with an existing schema. Does this ring any
>> bells?
>>
>>
>>
>>
>> --
>> =================
>> I-nnovate Software - Bespoke Software Development, uk wirral.
>> http://www.i-nnovate.net
>>
>> Easy Project Managment Online
>> http://www.task-mate.com
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>
>
>
>
>
> >

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Fluent NHibernate" group.
To post to this group, send email to fluent-nhibernate@googlegroups.com
To unsubscribe from this group, send email to 
fluent-nhibernate+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/fluent-nhibernate?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to