Skip to content

Commit

Permalink
Replace jcabi-matchers with hamcrest 2
Browse files Browse the repository at this point in the history
  • Loading branch information
shred committed Oct 13, 2018
1 parent 9d431d2 commit 565bb79
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,6 @@
import org.junit.BeforeClass;
import org.junit.Test;

import com.jcabi.matchers.RegexMatchers;

/**
* Unit tests for {@link CSRBuilder}.
*/
Expand Down Expand Up @@ -191,7 +189,7 @@ private void writerTest(CSRBuilder builder) throws IOException {
}

// Make sure PEM file is properly formatted
assertThat(pem, RegexMatchers.matchesPattern(
assertThat(pem, matchesPattern(
"-----BEGIN CERTIFICATE REQUEST-----[\\r\\n]+"
+ "([a-zA-Z0-9/+=]+[\\r\\n]+)+"
+ "-----END CERTIFICATE REQUEST-----[\\r\\n]*"));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,6 @@
import org.junit.BeforeClass;
import org.junit.Test;

import com.jcabi.matchers.RegexMatchers;

/**
* Unit tests for {@link KeyPairUtils}.
*/
Expand Down Expand Up @@ -73,7 +71,7 @@ public void testWriteAndRead() throws IOException {
}

// Make sure PEM file is properly formatted
assertThat(pem, RegexMatchers.matchesPattern(
assertThat(pem, matchesPattern(
"-----BEGIN RSA PRIVATE KEY-----[\\r\\n]+"
+ "([a-zA-Z0-9/+=]+[\\r\\n]+)+"
+ "-----END RSA PRIVATE KEY-----[\\r\\n]*"));
Expand Down Expand Up @@ -116,7 +114,7 @@ public void testWriteAndReadEC() throws IOException {
}

// Make sure PEM file is properly formatted
assertThat(pem, RegexMatchers.matchesPattern(
assertThat(pem, matchesPattern(
"-----BEGIN EC PRIVATE KEY-----[\\r\\n]+"
+ "([a-zA-Z0-9/+=]+[\\r\\n]+)+"
+ "-----END EC PRIVATE KEY-----[\\r\\n]*"));
Expand Down
11 changes: 3 additions & 8 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -228,16 +228,11 @@
</dependency>
<dependency>
<groupId>org.hamcrest</groupId>
<artifactId>hamcrest-library</artifactId>
<version>[1.3,)</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.jcabi</groupId>
<artifactId>jcabi-matchers</artifactId>
<version>[1.3,)</version>
<artifactId>java-hamcrest</artifactId>
<version>[2.0.0.0,)</version>
<scope>test</scope>
</dependency>

<dependency>
<groupId>uk.co.datumedge</groupId>
<artifactId>hamcrest-json</artifactId>
Expand Down

0 comments on commit 565bb79

Please sign in to comment.