These tasks can be run like so:
./gradlew publishGuide
codeStyle- runs all code style checkspublishGuide- generates the user guide in thegrails-doc/build/original-guide
These can be set on the command line like so:
./gradlew check -PskipCodeStyle
gebAtCheckWaiting- enables Geb atCheckWaitingonlyCoreTests- runs tests that do not include mongo, hibernate, or functionalonlyFunctionalTests- runs only grails-test-examples/* testsonlyHibernate5Tests- runs only a hibernate5 related testonlyHibernate7Tests- runs only a hibernate7 related testonlyMongodbTests- runs only a mongodb related testserializeMongoTests- if true, only integration tests from one mongo project will run at a timeskipCodeStyle- does not run code style checksskipCoreTests- does not run the "core" testsskipFunctionalTests- does not run the functional testsskipHibernate5Tests- does not run hibernate5 related testsskipHibernate7Tests- does not run hibernate7 related testsskipMongodbTests- does not run mongo related testsskipTests- no tests will run
Test classes tagged with @spock.lang.Tag('some-tag') can be run separately.
Tags are inherited from superclasses, so a test class is also included if any of its ancestors is tagged.
Example:
./gradlew iT -PincludeTestTags=gebAvailable project properties:
includeTestTags- comma-separated list of test tags to includeexcludeTestTags- comma-separated list of test tags to exclude
Example with multiple tags:
./gradlew iT -PincludeTestTags=geb,api-
DO_NOT_CACHE_TESTS- set to1(or any truthy value) to force everyTesttask to run every invocation, without needing--rerun-tasks. This skips both Gradle's build cache and theup-to-datecheck for tests, while leaving the rest of the build (compilation, resource processing, etc.) cacheable. Useful when chasing flaky tests that depend on test execution order across runs.DO_NOT_CACHE_TESTS=1 ./gradlew :grails-gsp:test
docker run -d --name mongo-on-docker -p 27017:27017 mongo