我无法调试(简单运行正常)我的单元测试。Squeryl 出现以下异常:
error while reflecting on metadata for (Some(private scala.Option
com.company.play.model.db.mapping.Position.orgUnit2id),Some(public scala.Option
com.company.play.model.db.mapping.Position.orgUnit2id()),None,Set(@org.squeryl.annotations.ColumnBase(optionType=class java.lang.Object, name=, length=-1, scale=-1, value=ORG_UNIT2ID))) of class com.company.play.model.db.mapping.Position
java.lang.RuntimeException: error while reflecting on metadata for (Some(private scala.Option com.company.play.model.db.mapping.Position.orgUnit2id),Some(public scala.Option com.company.play.model.db.mapping.Position.orgUnit2id()),None,Set(@org.squeryl.annotations.ColumnBase(optionType=class java.lang.Object, name=, length=-1, scale=-1, value=ORG_UNIT2ID))) of class com.company.play.model.db.mapping.Position
at org.squeryl.internals.PosoMetaData$$anonfun$4.apply(PosoMetaData.scala:115)
at org.squeryl.internals.PosoMetaData$$anonfun$4.apply(PosoMetaData.scala:80)
at org.squeryl.internals.PosoMetaData.<init>(PosoMetaData.scala:80)
at org.squeryl.View.<init>(View.scala:66)
at org.squeryl.Table.<init>(Table.scala:29)
at org.squeryl.Schema$class.table(Schema.scala:340)
at com.******.play.model.db.mapping.DBLibrary$.table(DBLibrary.scala:5)
...
Caused by: scala.MatchError: null
at org.squeryl.internals.FieldMetaData$$anon$1.build(FieldMetaData.scala:466)
at org.squeryl.internals.PosoMetaData$$anonfun$4.apply(PosoMetaData.scala:112)
... 22 more
我使用最新版本的IntelliJ IDEA(13.1.4)进行调试。在IDEA和控制台(sbt clean compile test)中都可以正常运行。