LoginSignup
0
0

More than 5 years have passed since last update.

ScalaTestでコンパイルエラーが発生した時

Last updated at Posted at 2017-01-19

少し躓いたので備忘録

今のとこ下記を記述すればコンパイルできるようになりました

build.sbt
libraryDependencies += "org.scalatest" %% "scalatest" % "3.0.1" % "test"

%%にして、ライブラリのScalaバージョンを消しているらしい(参考URLより)

3.0.1等のバージョンは下記を確認
ScalaTest
http://www.scalatest.org/user_guide

追記
Specs2の場合は下記を追加

build.sbt
libraryDependencies ++= Seq("org.specs2" %% "specs2-core" % "3.8.7" % "test")

scalacOptions in Test ++= Seq("-Yrangepos")

バージョンは下記を確認
https://etorreborre.github.io/specs2/website/SPECS2-3.8.7/quickstart.html

参考URL:

ScalaTestを動かそうとすると can't expand macros compiled by previous versions of Scala
http://dropout-shadow.hateblo.jp/entry/2016/01/04/153211

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0