Enable jdk-system-out Forbidden API checks on test sources
This commit is contained in:
parent
d14ae5f8b6
commit
e91fd09692
|
@ -64,7 +64,7 @@ class PrecommitTasks {
|
||||||
project.forbiddenApis {
|
project.forbiddenApis {
|
||||||
internalRuntimeForbidden = true
|
internalRuntimeForbidden = true
|
||||||
failOnUnsupportedJava = false
|
failOnUnsupportedJava = false
|
||||||
bundledSignatures = ['jdk-unsafe', 'jdk-deprecated']
|
bundledSignatures = ['jdk-unsafe', 'jdk-deprecated', 'jdk-system-out']
|
||||||
signaturesURLs = [getClass().getResource('/forbidden/jdk-signatures.txt'),
|
signaturesURLs = [getClass().getResource('/forbidden/jdk-signatures.txt'),
|
||||||
getClass().getResource('/forbidden/es-all-signatures.txt')]
|
getClass().getResource('/forbidden/es-all-signatures.txt')]
|
||||||
suppressAnnotations = ['**.SuppressForbidden']
|
suppressAnnotations = ['**.SuppressForbidden']
|
||||||
|
@ -72,7 +72,6 @@ class PrecommitTasks {
|
||||||
Task mainForbidden = project.tasks.findByName('forbiddenApisMain')
|
Task mainForbidden = project.tasks.findByName('forbiddenApisMain')
|
||||||
if (mainForbidden != null) {
|
if (mainForbidden != null) {
|
||||||
mainForbidden.configure {
|
mainForbidden.configure {
|
||||||
bundledSignatures += 'jdk-system-out'
|
|
||||||
signaturesURLs += getClass().getResource('/forbidden/es-core-signatures.txt')
|
signaturesURLs += getClass().getResource('/forbidden/es-core-signatures.txt')
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -29,7 +29,6 @@ subprojects {
|
||||||
|
|
||||||
// the main files are actually test files, so use the appropriate forbidden api sigs
|
// the main files are actually test files, so use the appropriate forbidden api sigs
|
||||||
forbiddenApisMain {
|
forbiddenApisMain {
|
||||||
bundledSignatures = ['jdk-unsafe', 'jdk-deprecated']
|
|
||||||
signaturesURLs = [PrecommitTasks.getResource('/forbidden/jdk-signatures.txt'),
|
signaturesURLs = [PrecommitTasks.getResource('/forbidden/jdk-signatures.txt'),
|
||||||
PrecommitTasks.getResource('/forbidden/es-signatures.txt'),
|
PrecommitTasks.getResource('/forbidden/es-signatures.txt'),
|
||||||
PrecommitTasks.getResource('/forbidden/es-test-signatures.txt')]
|
PrecommitTasks.getResource('/forbidden/es-test-signatures.txt')]
|
||||||
|
|
|
@ -38,7 +38,6 @@ compileTestJava.options.compilerArgs << '-Xlint:-rawtypes'
|
||||||
|
|
||||||
// the main files are actually test files, so use the appropriate forbidden api sigs
|
// the main files are actually test files, so use the appropriate forbidden api sigs
|
||||||
forbiddenApisMain {
|
forbiddenApisMain {
|
||||||
bundledSignatures = ['jdk-unsafe', 'jdk-deprecated']
|
|
||||||
signaturesURLs = [PrecommitTasks.getResource('/forbidden/all-signatures.txt'),
|
signaturesURLs = [PrecommitTasks.getResource('/forbidden/all-signatures.txt'),
|
||||||
PrecommitTasks.getResource('/forbidden/test-signatures.txt')]
|
PrecommitTasks.getResource('/forbidden/test-signatures.txt')]
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue