I replaced
the JUnitRunner
from scala-test for SpringJUnit4ClassRunner hoping for some magic, but
instead, things got even worse: java.lang.Exception: No runnable
methods.
Then I added a @Test annotation and switched from FunSpec to the JUnite-like FunSuite to no avail.
Next thing I did was, I removed the line containing "
@RunWith(classOf[JUnitRunner])" from my test class, included the dependency for scalatest-maven-plugin into the project's pom.xml
and followed the advice from
http://stackoverflow.com/questions/6282471/how-do-i-integrate-scalatest-with-spring
to include TestContextManager like so
new TestContextManager(classOf[MovieRepositoryTest]).prepareTestInstance(this)
describe("MovieRepository") {
...
}
mvn clean -Dtest=MovieRepositoryTest test
*** RUN ABORTED ***
java.lang.NoSuchMethodError: org.springframework.util.ClassUtils.determineCommonAncestor(Ljava/lang/Class;Ljava/lang/Class;)Ljava/lang/Class;
At least, there are now some classpathscanning activities in the log.
I'd glad, if anyone could demonstrate, how to make spring and scala-test work.