how to Unit test fluent mappings, with in memory sqlite when you got sequences

心不动则不痛 提交于 2019-12-11 00:23:40

问题


My Real db is oracle, and has sequences(not under my control). I wanna test the mappings with in memory sqlite db, I thought about a few options, do a sequence conventions(if possible) that will be active only when I'm on oracle, make the Id Mapping call another method that will resolve the id mapping by it self and ask some one about the configured db.

What is the best practice for my problem?


回答1:


Use the GenretedBy.Native([seqName]);



来源:https://stackoverflow.com/questions/4885231/how-to-unit-test-fluent-mappings-with-in-memory-sqlite-when-you-got-sequences

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!