From aa06344d8733a8d3cfd342a9cfc3690697745add Mon Sep 17 00:00:00 2001 From: Andreas Dangel Date: Tue, 17 Jan 2023 10:58:53 +0100 Subject: [PATCH] [core] Deprecate BaseCPDCLITest --- docs/pages/release_notes.md | 7 ++++--- .../main/java/net/sourceforge/pmd/cli/BaseCPDCLITest.java | 6 ++++++ 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/docs/pages/release_notes.md b/docs/pages/release_notes.md index ce9d636614..6b18cd7202 100644 --- a/docs/pages/release_notes.md +++ b/docs/pages/release_notes.md @@ -31,9 +31,10 @@ This is a {{ site.pmd.release_type }} release. {% jdoc core::AbstractConfiguration#getSourceEncoding() %} and {% jdoc core::AbstractConfiguration#setSourceEncoding(java.lang.String) %} instead. Both are available for `CPDConfiguration` which extends `AbstractConfiguration`. -* {% jdoc test::cli.BaseCLITest %} has been deprecated for removal without replacement. CLI tests should be done - in pmd-core only (and in PMD7 in pmd-cli). Individual language modules shouldn't need to test the CLI integration - logic again. Instead, the individual language modules should test their functionality as unit tests. +* {% jdoc test::cli.BaseCLITest %} and {% jdoc test::cli.BaseCPDCLITest %} have been deprecated for removal without + replacement. CLI tests should be done in pmd-core only (and in PMD7 in pmd-cli). Individual language modules + shouldn't need to test the CLI integration logic again. Instead, the individual language modules should test their + functionality as unit tests. ##### Internal APIs diff --git a/pmd-test/src/main/java/net/sourceforge/pmd/cli/BaseCPDCLITest.java b/pmd-test/src/main/java/net/sourceforge/pmd/cli/BaseCPDCLITest.java index 3380d7acc4..5d3aba216a 100644 --- a/pmd-test/src/main/java/net/sourceforge/pmd/cli/BaseCPDCLITest.java +++ b/pmd-test/src/main/java/net/sourceforge/pmd/cli/BaseCPDCLITest.java @@ -15,6 +15,12 @@ import org.junit.Before; import net.sourceforge.pmd.cpd.CPD; import net.sourceforge.pmd.cpd.CPDCommandLineInterface; +/** + * @deprecated This is deprecated for removal without replacement. CLI tests should be done in pmd-core only + * (and in PMD7 in pmd-cli). Individual language modules shouldn't need to test the CLI integration logic again. + * Instead, the individual language modules should test their functionality as unit tests. + */ +@Deprecated public abstract class BaseCPDCLITest { private ByteArrayOutputStream bufferStdout; private PrintStream originalStdout;