Skip to content

Commit

Permalink
Merge pull request #110 from StefanSpieker/assertions
Browse files Browse the repository at this point in the history
Use explicit imports instead of star to fix deprecation
  • Loading branch information
jglick authored Apr 19, 2023
2 parents ef51007 + a6e0576 commit cf943c8
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/test/java/hudson/tasks/AntJCasCCompatibilityTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import org.jvnet.hudson.test.RestartableJenkinsRule;

import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertTrue;
import static org.junit.Assert.assertNotNull;

public class AntJCasCCompatibilityTest extends RoundTripAbstractTest {

Expand All @@ -15,7 +15,7 @@ protected void assertConfiguredAsExpected(RestartableJenkinsRule restartableJenk
final Jenkins jenkins = restartableJenkinsRule.j.jenkins;

final Ant.DescriptorImpl descriptor = (Ant.DescriptorImpl) jenkins.getDescriptor(Ant.class);
assertTrue("The descriptor should not be null", descriptor != null);
assertNotNull("The descriptor should not be null", descriptor);

final Ant.AntInstallation[] installations = descriptor.getInstallations();
assertEquals("The installation has not retrieved", 2, installations.length);
Expand Down
11 changes: 9 additions & 2 deletions src/test/java/hudson/tasks/AntTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,15 @@
import java.util.Set;

import org.apache.commons.lang.SystemUtils;
import static org.hamcrest.Matchers.*;
import static org.junit.Assert.*;

import static org.hamcrest.MatcherAssert.assertThat;
import static org.hamcrest.Matchers.containsString;
import static org.hamcrest.Matchers.not;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertNull;
import static org.junit.Assert.assertTrue;
import static org.junit.Assert.fail;
import static org.junit.Assume.assumeFalse;
import static org.junit.Assume.assumeTrue;

Expand Down

0 comments on commit cf943c8

Please sign in to comment.