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

ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-net.git


The following commit(s) were added to refs/heads/master by this push:
     new 57923ff4 Local variable not needed
57923ff4 is described below

commit 57923ff4a61ff56dccec37f6e306e6c2b822d4a7
Author: Gary Gregory <[email protected]>
AuthorDate: Mon Nov 7 10:29:23 2022 -0500

    Local variable not needed
---
 .../java/org/apache/commons/net/smtp/SimpleSMTPHeaderTestCase.java     | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git 
a/src/test/java/org/apache/commons/net/smtp/SimpleSMTPHeaderTestCase.java 
b/src/test/java/org/apache/commons/net/smtp/SimpleSMTPHeaderTestCase.java
index 62a73a9c..7c50c5e5 100644
--- a/src/test/java/org/apache/commons/net/smtp/SimpleSMTPHeaderTestCase.java
+++ b/src/test/java/org/apache/commons/net/smtp/SimpleSMTPHeaderTestCase.java
@@ -107,8 +107,7 @@ public class SimpleSMTPHeaderTestCase {
 
     @Test
     public void testToStringNoFrom() {
-        final Executable testMethod = () -> new SimpleSMTPHeader(null, null, 
null);
-        assertThrows(IllegalArgumentException.class, testMethod);
+        assertThrows(IllegalArgumentException.class, () -> new 
SimpleSMTPHeader(null, null, null));
     }
 
     @Test

Reply via email to