0

在 project/Build.scala 文件定义为

val main = PlayProject(appName, appVersion, appDependencies, mainLang = JAVA).settings(defaultScalaSettings:_*).settings(
    ,resourceDirectory in Test <<= baseDirectory(_ / "test-resources")
)

运行show test:resource-directories会显示

[info] List(C:\Users\grigocn\work\reliable-transport-ui\test-resources, C:\Users\grigocn\work\reliable-transport-ui\target\scala-2.9.1\resource_managed\test)

但是运行eclipsify不会将该文件夹添加到eclipse项目中。

我应该如何配置项目让 eclipsify 插件知道这个资源目录?

4

1 回答 1

0

Try adding this to the .settings() block of your Build.scala:

unmanagedClasspath in Test <+= baseDirectory map { bd => Attributed.blank(bd / "test-resources") }

This is from a Play 2.1 project, but I don't think the syntax changed between 2.0 and 2.1.

于 2013-04-29T04:54:48.157 回答