Skip to content

Commit

Permalink
Remove unused imports of ServletException (#646)
Browse files Browse the repository at this point in the history
  • Loading branch information
Vlatombe authored Sep 10, 2024
1 parent 0e1837b commit 8d143ac
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 15 deletions.
8 changes: 0 additions & 8 deletions src/main/java/hudson/tasks/junit/TestObject.java
Original file line number Diff line number Diff line change
Expand Up @@ -187,12 +187,4 @@ public TestObject getResultInRun(Run<?, ?> run) {
public abstract int getTotalCount();

public abstract History getHistory();

// public abstract Object getDynamic(String token, StaplerRequest req,
// StaplerResponse rsp);
//
// public abstract HttpResponse doSubmitDescription(
// @QueryParameter String description) throws IOException,
// ServletException;

}
4 changes: 1 addition & 3 deletions src/main/java/hudson/tasks/test/TestObject.java
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@
import java.util.WeakHashMap;
import java.util.logging.Level;
import java.util.logging.Logger;
import javax.servlet.ServletException;
import jenkins.model.Jenkins;
import org.kohsuke.stapler.HttpRedirect;
import org.kohsuke.stapler.HttpResponse;
Expand Down Expand Up @@ -480,8 +479,7 @@ public Object getDynamic(String token, StaplerRequest req, StaplerResponse rsp)
}

@RequirePOST
public synchronized HttpResponse doSubmitDescription(@QueryParameter String description)
throws IOException, ServletException {
public synchronized HttpResponse doSubmitDescription(@QueryParameter String description) throws IOException {
Run<?, ?> run = getRun();
if (run == null) {
LOGGER.severe("getRun() is null, can't save description.");
Expand Down
7 changes: 3 additions & 4 deletions src/main/java/hudson/tasks/test/TestResultProjectAction.java
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@
import io.jenkins.plugins.junit.storage.TestResultImpl;
import java.io.IOException;
import java.util.List;
import javax.servlet.ServletException;
import javax.servlet.http.Cookie;
import javax.servlet.http.HttpServletResponse;
import org.kohsuke.stapler.Ancestor;
Expand Down Expand Up @@ -172,7 +171,7 @@ private TestResultActionIterable createBuildHistory(final Run<?, ?> lastComplete
* @deprecated Replaced by echarts in TODO

Check warning on line 171 in src/main/java/hudson/tasks/test/TestResultProjectAction.java

View check run for this annotation

ci.jenkins.io / Open Tasks Scanner

TODO

NORMAL:
*/
@Deprecated
public void doTrend(final StaplerRequest req, final StaplerResponse rsp) throws IOException, ServletException {
public void doTrend(final StaplerRequest req, final StaplerResponse rsp) throws IOException {
AbstractTestResultAction a = getLastTestResultAction();
if (a != null) {
a.doGraph(req, rsp);
Expand All @@ -187,7 +186,7 @@ public void doTrend(final StaplerRequest req, final StaplerResponse rsp) throws
* @deprecated Replaced by echarts in TODO

Check warning on line 186 in src/main/java/hudson/tasks/test/TestResultProjectAction.java

View check run for this annotation

ci.jenkins.io / Open Tasks Scanner

TODO

NORMAL:
*/
@Deprecated
public void doTrendMap(final StaplerRequest req, final StaplerResponse rsp) throws IOException, ServletException {
public void doTrendMap(final StaplerRequest req, final StaplerResponse rsp) throws IOException {
AbstractTestResultAction a = getLastTestResultAction();
if (a != null) {
a.doGraphMap(req, rsp);
Expand All @@ -199,7 +198,7 @@ public void doTrendMap(final StaplerRequest req, final StaplerResponse rsp) thro
/**
* Changes the test result report display mode.
*/
public void doFlipTrend(final StaplerRequest req, final StaplerResponse rsp) throws IOException, ServletException {
public void doFlipTrend(final StaplerRequest req, final StaplerResponse rsp) throws IOException {
boolean failureOnly = false;

// check the current preference value
Expand Down

0 comments on commit 8d143ac

Please sign in to comment.