run non-mainnet ATs on PRs, split into sub groups (#5502)

* run non-mainnet ATs on PRs, split into sets

* split privacy and permissioning

Signed-off-by: Sally MacFarlane <macfarla.github@gmail.com>

---------

Signed-off-by: Sally MacFarlane <macfarla.github@gmail.com>
pull/5514/head
Sally MacFarlane 2 years ago committed by GitHub
parent ba2ecc01ba
commit 21992b7a5c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 58
      .circleci/config.yml
  2. 58
      acceptance-tests/tests/build.gradle

@ -240,7 +240,7 @@ jobs:
- capture_test_results - capture_test_results
- capture_test_logs - capture_test_logs
acceptanceTestsNonMainnet: acceptanceTestsCliqueBft:
parallelism: 6 parallelism: 6
executor: xl_machine_executor executor: xl_machine_executor
steps: steps:
@ -258,7 +258,51 @@ jobs:
| circleci tests split --split-by=timings --timings-type=classname) | circleci tests split --split-by=timings --timings-type=classname)
# Format the arguments to "./gradlew test" # Format the arguments to "./gradlew test"
GRADLE_ARGS=$(echo $CLASSNAMES | awk '{for (i=1; i<=NF; i++) print "--tests",$i}') GRADLE_ARGS=$(echo $CLASSNAMES | awk '{for (i=1; i<=NF; i++) print "--tests",$i}')
./gradlew --no-daemon acceptanceTestNonMainnet $GRADLE_ARGS ./gradlew --no-daemon acceptanceTestCliqueBft $GRADLE_ARGS
- capture_test_results
- capture_test_logs
acceptanceTestsPrivacy:
parallelism: 6
executor: xl_machine_executor
steps:
- prepare
- attach_workspace:
at: ~/project
- run:
name: AcceptanceTests (Non-Mainnet)
no_output_timeout: 20m
command: |
CLASSNAMES=$(circleci tests glob "acceptance-tests/tests/src/test/java/**/*.java" \
| sed 's@.*/src/test/java/@@' \
| sed 's@/@.@g' \
| sed 's/.\{5\}$//' \
| circleci tests split --split-by=timings --timings-type=classname)
# Format the arguments to "./gradlew test"
GRADLE_ARGS=$(echo $CLASSNAMES | awk '{for (i=1; i<=NF; i++) print "--tests",$i}')
./gradlew --no-daemon acceptanceTestPrivacy $GRADLE_ARGS
- capture_test_results
- capture_test_logs
acceptanceTestsPermissioning:
parallelism: 6
executor: xl_machine_executor
steps:
- prepare
- attach_workspace:
at: ~/project
- run:
name: AcceptanceTests (Non-Mainnet)
no_output_timeout: 20m
command: |
CLASSNAMES=$(circleci tests glob "acceptance-tests/tests/src/test/java/**/*.java" \
| sed 's@.*/src/test/java/@@' \
| sed 's@/@.@g' \
| sed 's/.\{5\}$//' \
| circleci tests split --split-by=timings --timings-type=classname)
# Format the arguments to "./gradlew test"
GRADLE_ARGS=$(echo $CLASSNAMES | awk '{for (i=1; i<=NF; i++) print "--tests",$i}')
./gradlew --no-daemon acceptanceTestPermissioning $GRADLE_ARGS
- capture_test_results - capture_test_results
- capture_test_logs - capture_test_logs
@ -401,6 +445,15 @@ workflows:
- acceptanceTests: - acceptanceTests:
requires: requires:
- assemble - assemble
- acceptanceTestsCliqueBft:
requires:
- assemble
- acceptanceTestsPrivacy:
requires:
- assemble
- acceptanceTestsPermissioning:
requires:
- assemble
- buildDocker: - buildDocker:
requires: requires:
- assemble - assemble
@ -472,4 +525,3 @@ workflows:
jobs: jobs:
- assemble - assemble
- dockerScan - dockerScan
- acceptanceTestsNonMainnet

@ -155,11 +155,36 @@ task acceptanceTestMainnet(type: Test) {
doFirst { mkdir "${buildDir}/jvmErrorLogs" } doFirst { mkdir "${buildDir}/jvmErrorLogs" }
} }
task acceptanceTestNonMainnet(type: Test) { task acceptanceTestCliqueBft(type: Test) {
inputs.property "integration.date", LocalTime.now() // so it runs at every invocation inputs.property "integration.date", LocalTime.now() // so it runs at every invocation
include '**/bft/**' include '**/bft/**'
include '**/clique/**' include '**/clique/**'
include '**/permissioning/**'
useJUnitPlatform {}
dependsOn(rootProject.installDist)
setSystemProperties(test.getSystemProperties())
systemProperty 'acctests.runBesuAsProcess', 'true'
systemProperty 'java.security.properties', "${buildDir}/resources/test/acceptanceTesting.security"
mustRunAfter rootProject.subprojects*.test
description = 'Runs Clique and BFT Besu acceptance tests.'
group = 'verification'
jvmArgs "-XX:ErrorFile=${buildDir}/jvmErrorLogs/java_err_pid%p.log"
testLogging {
exceptionFormat = 'full'
showStackTraces = true
showStandardStreams = Boolean.getBoolean('acctests.showStandardStreams')
showExceptions = true
showCauses = true
}
doFirst { mkdir "${buildDir}/jvmErrorLogs" }
}
task acceptanceTestPrivacy(type: Test) {
inputs.property "integration.date", LocalTime.now() // so it runs at every invocation
include '**/privacy/**' include '**/privacy/**'
useJUnitPlatform {} useJUnitPlatform {}
@ -169,7 +194,34 @@ task acceptanceTestNonMainnet(type: Test) {
systemProperty 'acctests.runBesuAsProcess', 'true' systemProperty 'acctests.runBesuAsProcess', 'true'
systemProperty 'java.security.properties', "${buildDir}/resources/test/acceptanceTesting.security" systemProperty 'java.security.properties', "${buildDir}/resources/test/acceptanceTesting.security"
mustRunAfter rootProject.subprojects*.test mustRunAfter rootProject.subprojects*.test
description = 'Runs NON-MAINNET Besu acceptance tests for permissioning and privacy (excluding mainnet features).' description = 'Runs Privacy Besu acceptance tests.'
group = 'verification'
jvmArgs "-XX:ErrorFile=${buildDir}/jvmErrorLogs/java_err_pid%p.log"
testLogging {
exceptionFormat = 'full'
showStackTraces = true
showStandardStreams = Boolean.getBoolean('acctests.showStandardStreams')
showExceptions = true
showCauses = true
}
doFirst { mkdir "${buildDir}/jvmErrorLogs" }
}
task acceptanceTestPermissioning(type: Test) {
inputs.property "integration.date", LocalTime.now() // so it runs at every invocation
include '**/permissioning/**'
useJUnitPlatform {}
dependsOn(rootProject.installDist)
setSystemProperties(test.getSystemProperties())
systemProperty 'acctests.runBesuAsProcess', 'true'
systemProperty 'java.security.properties', "${buildDir}/resources/test/acceptanceTesting.security"
mustRunAfter rootProject.subprojects*.test
description = 'Runs Permissioning Besu acceptance tests.'
group = 'verification' group = 'verification'
jvmArgs "-XX:ErrorFile=${buildDir}/jvmErrorLogs/java_err_pid%p.log" jvmArgs "-XX:ErrorFile=${buildDir}/jvmErrorLogs/java_err_pid%p.log"

Loading…
Cancel
Save