我有一個類需要進行單元測試。的結構如下: public class classToBeTested{
public returnType function1(){
//creation of variable V
return new classA(V).map();
}
}
類CLASSA如下: public class classA{
我用wordspec一種行使下列情形 case class Assertion(expected:Any, actual:Any)
case class TestCases(name:String, assertions:List[Assertions])
val testCases = List[TestCases]
"Testcases" should {
testCases
考慮以下org.scalatest.TagAnnotation子類: public class TestSizeTags {
/** Tests with crazy long runtimes **/
@org.scalatest.TagAnnotation
@Inherited
@Retention(RetentionPolicy.RUNTIME)