我正在运行Scala 2.9.2和ScalaTest 2.0M4。我有一个ScalaTest jar的本地副本,现在想从repo中自动获取它。
Scalatest site说了这个:
..is available [at] the Sonatype OSS Maven repository (which is mirrored on the central Maven repository as well):
group id: org.scalatest
artifact id: scalatest_2.9.0 (for Scala 2.9.0+)
version: 2.0.M4
Or via sbt (version 0.10 or higher) with:
libraryDependencies += "org.scalatest" %% "scalatest" % "2.0.M4" % "test"
现在,我必须将“解析器”添加到我的'project / plugins.sbt'才能达到此目的吗?
答案 0 :(得分:2)
有了这个:
在project/plugins.sbt
:
resolvers += "SonaType" at "https://oss.sonatype.org/content/groups/public"
在build.sbt
:
libraryDependencies += "org.scalatest" %% "scalatest" % "latest.integration" % "test"
我没有得到的是在'libraryDependencies'之后添加'in Test'不起作用但是给出了:
object scalatest is not a member of package org
好吧,我会留在这里。如果有人知道为什么“在测试中”不受欢迎,请给出一条线。谢谢。