score:1

I think you're looking for assertEq, take a look at the documentation for SUnit's Assert

assertEq(obj1, obj2)

Alternatively, you could use something a little more verbose while sticking to JUnit and Scalatest. (docs)

assert(obj1 eq obj2, "Some meaningful message")

Related Query

More Query from same tag