mirror of
https://github.com/AppleCommander/AppleCommander.git
synced 2024-12-26 03:33:00 +00:00
Updated ant-ac
to run Ant tests from the Gradle build. #80
This commit is contained in:
parent
867d73e9b2
commit
125fb818ee
@ -29,9 +29,11 @@ BUILD SUCCESSFUL in 554ms
|
|||||||
19 actionable tasks: 19 up-to-date
|
19 actionable tasks: 19 up-to-date
|
||||||
```
|
```
|
||||||
|
|
||||||
## Testing for Ant Task
|
## Testing of the Ant Task
|
||||||
|
|
||||||
The Apache Ant Task has been added as an independent "application" to the Gradle source structure. It resides in `app/ant-ac`. To test the Ant Task, there is an actual Ant build script available. Run this script from the AppleCommander project directory -- it should figure out paths from that starting position.
|
The Ant Task testing has been enbedded within the Gradle build for Ant itself and does not need to be run separately. The `app/ant-ac/build.gradle` script reads from the `app/ant-ac/src/test/resources/build-testacant.xml` and executes the tests as part of the testing task.
|
||||||
|
|
||||||
|
However, if the Ant script itself is being worked upon, it may be useful to run it outside of the build process. Run the following from the main AppleCommander project directory; note that this requires Ant to be installed and active. As usual, note your Java versions and ensure that Java 11 is active.
|
||||||
|
|
||||||
```
|
```
|
||||||
$ ant -f app/ant-ac/src/test/resources/build-testacant.xml
|
$ ant -f app/ant-ac/src/test/resources/build-testacant.xml
|
||||||
|
@ -24,3 +24,11 @@ jar {
|
|||||||
configurations.runtimeClasspath.collect { it.isDirectory() ? it : zipTree(it) }
|
configurations.runtimeClasspath.collect { it.isDirectory() ? it : zipTree(it) }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Automagically run the Ant tests as part of the build process.
|
||||||
|
ant.importBuild('src/test/resources/build-testacant.xml') { antTargetName ->
|
||||||
|
'anttest-' + antTargetName
|
||||||
|
}
|
||||||
|
tasks.named('test') {
|
||||||
|
finalizedBy('anttest-all')
|
||||||
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user