我有一个名为webService的域类。当我每次得到相同的异常时都试图测试它时无法添加Service类[class ... WebService]。这不是服务!
org.codehaus.groovy.grails.exceptions.GrailsConfigurationException: Cannot add Service class [class ...WebService]. It is not a Service!
at grails.test.mixin.services.ServiceUnitTestMixin.mockService(ServiceUnitTestMixin.groovy:46)
at org.spockframework.util.ReflectionUtil.invokeMethod(ReflectionUtil.java:138)
at org.spockframework.runtime.extension.builtin.JUnitFixtureMethodsExtension$FixtureType$FixtureMethodInterceptor.intercept(JUnitFixtureMethodsExtension.java:145)
at org.spockframework.runtime.extension.MethodInvocation.proceed(MethodInvocation.java:84)
at org.spockframework.util.ReflectionUtil.invokeMethod(ReflectionUtil.java:138)
|Completed 1 spock test, 1 failed in 0m 0s
我只是想找一些解决方法,也许有人有想法?