Where is IDataContext?

Surprise, when trying to write test code to mock LINQ to SQL’s datacontext object, I could not find IDataContext! Hope Microsoft will add it in offical release. We need unit test.

Found this interesting blog, building Generic DAO using Linq to SQL, idea is identical to NHibernate’s DAO. By doing this, we will have an option to operate data DAO layer instead of DataContext object.

Advertisements

2 thoughts on “Where is IDataContext?

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s