2016-05-24 61 views
0

我測試Grails應用程序,但我收到此錯誤信息:錯誤檢測斯波克頂杆的Grails在v2.4.3

我試圖做單元測試。我的Grails版本是2.4.3

執行腳本TestApp出錯:java.lang.ClassNotFoundException:grails.plugin.spock。

這是我的代碼:

@TestFor(TrackEmailController) 
@Mock(TrackEmail) 
class TrackEmailUnit2Spec extends Specification { 

    def setup() { 
    } 

    def cleanup() { 
    } 

    void "test something"() { 
    } 

    void 'test mandrillEventsEndPoint'() { 
     when: 
     controller.mandrillEventsEndPoint() 

     then: 
     response.text == 'mandrill Events End Point' 
    } 
} 

回答

0

你可以對你是如何運行你的測試用例更具體一點,你是如何整合斯波克的依賴?或者也許提供一個github鏈接來複制這個問題?