From fbb0c547a659a69447cf90648cecff7e3d5ea0e7 Mon Sep 17 00:00:00 2001 From: Jesse Glick Date: Wed, 18 Dec 2024 17:34:27 -0500 Subject: [PATCH] Deprecating `JenkinsRule.setQuietPeriod` (#887) --- src/main/java/jenkins/model/JenkinsAdaptor.java | 3 ++- src/main/java/org/jvnet/hudson/test/JenkinsRule.java | 4 ++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/src/main/java/jenkins/model/JenkinsAdaptor.java b/src/main/java/jenkins/model/JenkinsAdaptor.java index efe14b9cb..48c5bca77 100644 --- a/src/main/java/jenkins/model/JenkinsAdaptor.java +++ b/src/main/java/jenkins/model/JenkinsAdaptor.java @@ -1,8 +1,9 @@ package jenkins.model; /** - * Access the package protected quiet period + * @deprecated use {@link Jenkins#setQuietPeriod} */ +@Deprecated public class JenkinsAdaptor { public static void setQuietPeriod(Jenkins jenkins, int quietPeriod) { jenkins.quietPeriod = quietPeriod; diff --git a/src/main/java/org/jvnet/hudson/test/JenkinsRule.java b/src/main/java/org/jvnet/hudson/test/JenkinsRule.java index 7a55f4f5b..5233f0869 100644 --- a/src/main/java/org/jvnet/hudson/test/JenkinsRule.java +++ b/src/main/java/org/jvnet/hudson/test/JenkinsRule.java @@ -1888,6 +1888,10 @@ public void assertEqualBeans(Object lhs, Object rhs, String properties) throws I } } + /** + * @deprecated use {@link Jenkins#setQuietPeriod} + */ + @Deprecated public void setQuietPeriod(int qp) { JenkinsAdaptor.setQuietPeriod(jenkins, qp); }