]> Sergey Matveev's repositories - public-inbox.git/blobdiff - t/address.t
treewide: run update-copyrights from gnulib for 2019
[public-inbox.git] / t / address.t
index e7c0d6a8132516dd6649ea88234a4123016f7940..6f4bff6c42928f4707355d9c25b286f1e6dac042 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright (C) 2016-2019 all contributors <meta@public-inbox.org>
+# Copyright (C) 2016-2020 all contributors <meta@public-inbox.org>
 # License: AGPL-3.0+ <https://www.gnu.org/licenses/agpl-3.0.txt>
 use strict;
 use warnings;
@@ -38,6 +38,11 @@ sub test_pkg {
 
        @names = $names->('"Quote Unneeded" <user@example.com>');
        is_deeply(['Quote Unneeded'], \@names, 'extra quotes dropped');
+
+       my @emails = $emails->('Local User <user>');
+       is_deeply([], \@emails , 'no address for local address');
+       @names = $emails->('Local User <user>');
+       is_deeply([], \@names, 'no address, no name');
 }
 
 test_pkg('PublicInbox::Address');