You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-dev@james.apache.org by bt...@apache.org on 2019/11/18 02:50:47 UTC

[james-project] 13/44: [Refactoring] MailboxMessageResultImplTest: Do not declare unthrown exceptions

This is an automated email from the ASF dual-hosted git repository.

btellier pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/james-project.git

commit a08d632a38311ac394dbd5acf9c25adfb977c292
Author: Benoit Tellier <bt...@linagora.com>
AuthorDate: Thu Nov 14 11:01:43 2019 +0700

    [Refactoring] MailboxMessageResultImplTest: Do not declare unthrown exceptions
---
 .../store/MailboxMessageResultImplTest.java        | 26 ++++++++++------------
 1 file changed, 12 insertions(+), 14 deletions(-)

diff --git a/mailbox/store/src/test/java/org/apache/james/mailbox/store/MailboxMessageResultImplTest.java b/mailbox/store/src/test/java/org/apache/james/mailbox/store/MailboxMessageResultImplTest.java
index 12d2171..e8baaac 100644
--- a/mailbox/store/src/test/java/org/apache/james/mailbox/store/MailboxMessageResultImplTest.java
+++ b/mailbox/store/src/test/java/org/apache/james/mailbox/store/MailboxMessageResultImplTest.java
@@ -60,45 +60,45 @@ public class MailboxMessageResultImplTest {
 
 
     @Test
-    public void testEqualsNull() throws Exception {
+    public void testEqualsNull() {
         assertThat(msgResultA).isNotNull();
     }
 
 
     @Test
-    public void testEqualsReflexive() throws Exception {
+    public void testEqualsReflexive() {
         assertThat(msgResultA).isEqualTo(msgResultA);
     }
 
 
     @Test
-    public void testCompareToReflexive() throws Exception {
+    public void testCompareToReflexive() {
         assertThat(msgResultA.compareTo(msgResultA)).isEqualTo(0);
     }
 
 
     @Test
-    public void testHashCodeReflexive() throws Exception {
+    public void testHashCodeReflexive() {
         assertThat(msgResultA.hashCode()).isEqualTo(msgResultA.hashCode());
     }
 
 
     @Test
-    public void testEqualsSymmetric() throws Exception {
+    public void testEqualsSymmetric() {
         assertThat(msgResultACopy).isEqualTo(msgResultA);
         assertThat(msgResultA).isEqualTo(msgResultACopy);
     }
 
 
     @Test
-    public void testHashCodeSymmetric() throws Exception {
+    public void testHashCodeSymmetric() {
         assertThat(msgResultACopy.hashCode()).isEqualTo(msgResultA.hashCode());
         assertThat(msgResultA.hashCode()).isEqualTo(msgResultACopy.hashCode());
     }
 
 
     @Test
-    public void testEqualsTransitive() throws Exception {
+    public void testEqualsTransitive() {
         assertThat(msgResultACopy).isEqualTo(msgResultA);
         assertThat(msgResultB).isEqualTo(msgResultACopy);
         assertThat(msgResultB).isEqualTo(msgResultA);
@@ -106,7 +106,7 @@ public class MailboxMessageResultImplTest {
 
 
     @Test
-    public void testCompareToTransitive() throws Exception {
+    public void testCompareToTransitive() {
         assertThat(msgResultA.compareTo(msgResultACopy)).isEqualTo(0);
         assertThat(msgResultACopy.compareTo(msgResultB)).isEqualTo(0);
         assertThat(msgResultA.compareTo(msgResultB)).isEqualTo(0);
@@ -114,7 +114,7 @@ public class MailboxMessageResultImplTest {
 
 
     @Test
-    public void testHashCodeTransitive() throws Exception {
+    public void testHashCodeTransitive() {
         assertThat(msgResultACopy.hashCode()).isEqualTo(msgResultA.hashCode());
         assertThat(msgResultB.hashCode()).isEqualTo(msgResultACopy.hashCode());
         assertThat(msgResultB.hashCode()).isEqualTo(msgResultA.hashCode());
@@ -122,20 +122,18 @@ public class MailboxMessageResultImplTest {
 
 
     @Test
-    public void testNotEqualDiffValue() throws Exception {
+    public void testNotEqualDiffValue() {
         assertThat(msgResultA).isNotEqualTo(msgResultC);
         assertThat(msgResultC).isNotEqualTo(msgResultA);
     }
 
     @Test
-    public void testShouldReturnPositiveWhenFirstGreaterThanSecond()
-            throws Exception {
+    public void testShouldReturnPositiveWhenFirstGreaterThanSecond() {
         assertThat(msgResultC.compareTo(msgResultB) > 0).isTrue();
     }
 
     @Test
-    public void testShouldReturnNegativeWhenFirstLessThanSecond()
-            throws Exception {
+    public void testShouldReturnNegativeWhenFirstLessThanSecond() {
         assertThat(msgResultB.compareTo(msgResultC) < 0).isTrue();
     }
 }
\ No newline at end of file


---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org