Saturday, 2 January 2016

scalatest-maven-plugin issue

When use scalatest-maven-plugin, you may encounter below error:

[INFO] --- scalatest-maven-plugin:1.0:test (test) @ pos3-adapter ---
Exception in thread "ScalaTest-main" java.lang.IllegalArgumentException: Use of A was deprecated in ScalaTest 1.0 and removed in 1.5. Please check the Scaladoc documentation of org.scalatest.Runner for information on valid Reporter config parameters.
  at org.scalatest.tools.Runner$.parseConfigSet(Runner.scala:1470)
  at org.scalatest.tools.Runner$.buildFileReporterConfigurationList$1(Runner.scala:1700)
  at org.scalatest.tools.Runner$.parseReporterArgsIntoConfigurations(Runner.scala:1704)
  at org.scalatest.tools.Runner$.runOptionallyWithPassFailReporter(Runner.scala:923)
  at org.scalatest.tools.Runner$.main(Runner.scala:860)
  at org.scalatest.tools.Runner.main(Runner.scala)

The ScalaTest Maven plugin contains two "mojos". The test mojo is for "mvn test" commands, and the reporter mojo is for "mvn site" commands.

Solution:


Disable reporter mojo by removing all reporter relevant setting in the <configuration> tag

Reference:

No comments:

Post a Comment