You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by pa...@apache.org on 2017/10/15 08:58:32 UTC
[text] UnicodeUnpairedSurrogateRemoverTest: use assertTrue and
assertFalse
Repository: commons-text
Updated Branches:
refs/heads/master 17e5ee725 -> 51645b4f0
UnicodeUnpairedSurrogateRemoverTest: use assertTrue and assertFalse
Project: http://git-wip-us.apache.org/repos/asf/commons-text/repo
Commit: http://git-wip-us.apache.org/repos/asf/commons-text/commit/51645b4f
Tree: http://git-wip-us.apache.org/repos/asf/commons-text/tree/51645b4f
Diff: http://git-wip-us.apache.org/repos/asf/commons-text/diff/51645b4f
Branch: refs/heads/master
Commit: 51645b4f0653c2ceae59eba0b2ea09fd5f4b8c0f
Parents: 17e5ee7
Author: Pascal Schumacher <pa...@gmx.net>
Authored: Sun Oct 15 10:56:46 2017 +0200
Committer: Pascal Schumacher <pa...@gmx.net>
Committed: Sun Oct 15 10:56:46 2017 +0200
----------------------------------------------------------------------
.../translate/UnicodeUnpairedSurrogateRemoverTest.java | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/commons-text/blob/51645b4f/src/test/java/org/apache/commons/text/translate/UnicodeUnpairedSurrogateRemoverTest.java
----------------------------------------------------------------------
diff --git a/src/test/java/org/apache/commons/text/translate/UnicodeUnpairedSurrogateRemoverTest.java b/src/test/java/org/apache/commons/text/translate/UnicodeUnpairedSurrogateRemoverTest.java
index 6f67e11..cc1627d 100644
--- a/src/test/java/org/apache/commons/text/translate/UnicodeUnpairedSurrogateRemoverTest.java
+++ b/src/test/java/org/apache/commons/text/translate/UnicodeUnpairedSurrogateRemoverTest.java
@@ -22,6 +22,8 @@ import java.io.CharArrayWriter;
import java.io.IOException;
import static org.junit.Assert.assertEquals;
+import static org.junit.Assert.assertFalse;
+import static org.junit.Assert.assertTrue;
/**
* Unit tests for {@link UnicodeUnpairedSurrogateRemover}.
@@ -32,15 +34,15 @@ public class UnicodeUnpairedSurrogateRemoverTest {
@Test
public void testValidCharacters() throws IOException {
- assertEquals(false, subject.translate(0xd7ff, writer));
- assertEquals(false, subject.translate(0xe000, writer));
+ assertFalse(subject.translate(0xd7ff, writer));
+ assertFalse(subject.translate(0xe000, writer));
assertEquals(0, writer.size());
}
@Test
public void testInvalidCharacters() throws IOException {
- assertEquals(true, subject.translate(0xd800, writer));
- assertEquals(true, subject.translate(0xdfff, writer));
+ assertTrue(subject.translate(0xd800, writer));
+ assertTrue(subject.translate(0xdfff, writer));
assertEquals(0, writer.size());
}
}