grailstestingspockgrails-2.5

grails 2.5.1 ignores Spock functional tests


I just migrated an application from grails 2.2.4 to grails 2.5.1. Now spock tests are not executed. The test directory looks as following:

test
   - unit
      - FirstSpec
      - SecondSpec
      - ... (more Spock tests)  
   - functional
      - FirstTests
      - FirstSpec
      - ... (more JUnit & Spock tests)

Following behavior occurs:

grails test-app unit:spock

does not run any test

grails test-app unit:

runs all spock unit tests

grails test-app functional:spock

does not run any tests

grails test-app functional:

runs only JUnit functional tests

With grails 2.2.4 all test have been executed. I followed the migration guide provided at the grails homepage (removing spock-plugin etc.) Does anyone have an idea what the problem may be?


Solution

  • I had the same problem. This plugin adds support for functional spock tests: https://grails.org/plugin/functional-spock

    I don't know why this functionality is not provided by default.

    Regards,Rumpel