SaaS CMS has officially launched! Learn more now.

Unit/Integration Tests - Commerce 7,5



Is there anybody who knows how I can initialize commerce 7,5 to get productentities within a test class?

Thanks in advance!

Dec 09, 2013 17:25

To make your class testable you should make it dependent on the IContentRepository or IContentLoader (in contrast to using DataFactory). Then use your favorite mock frame work to mock the dependency and work with your test data in your unit test.

Dec 10, 2013 20:18
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.