Skip to content

Latest commit

 

History

History
22 lines (14 loc) · 1.24 KB

HACKING.adoc

File metadata and controls

22 lines (14 loc) · 1.24 KB

Running Tests

This project has both unit tests and integration tests. In our context the distinguishing point is that integration tests need network connectivity, and unit tests need no more than local file system access. We also expect unit tests to be very quick, whereas integration tests are allowed to take a little longer.

Unit tests are in 'src/test' and integration tests are in 'src/integTest'. To run integration tests you would need to do ./gradlew check or ./gradlew build. For unittests just doing ./gradlew test is enough.

Test logging is controlled via logback-test.xml. Be aware that integration tests generate a lot of debug information. Please do not commit the config file back with DEBUG turned on.

Running single test suites

If you only want to run the unittests in say JRubyPlugin then you can do ./gradlew test --tests JRubyPlugin. In a similar manner for integration tests one can do ./gradlew integrationTest --tests JRubyIntegrationSpec.

Running tests in IntelliJ

Go to FileSettingsBuild, Execution, DeploymentGradleRunner, then check Delete build/run actions to Gradle and select Platform Test Runner.

On a Mac use IntelliJ IDEAPreferences instead of File/Settings.