diff options
Diffstat (limited to 't/watch_nntp.t')
-rw-r--r-- | t/watch_nntp.t | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/t/watch_nntp.t b/t/watch_nntp.t new file mode 100644 index 00000000..f919930e --- /dev/null +++ b/t/watch_nntp.t @@ -0,0 +1,15 @@ +# Copyright (C) 2020 all contributors <meta@public-inbox.org> +# License: AGPL-3.0+ <https://www.gnu.org/licenses/agpl-3.0.txt> +use strict; +use Test::More; +use PublicInbox::Config; +# see t/nntpd*.t for tests against a live NNTP server + +use_ok 'PublicInbox::WatchMaildir'; +my $nntp_url = \&PublicInbox::WatchMaildir::nntp_url; +is('news://example.com/inbox.foo', + $nntp_url->('NEWS://examplE.com/inbox.foo'), 'lowercased'); +is('snews://example.com/inbox.foo', + $nntp_url->('nntps://example.com/inbox.foo'), 'nntps:// is snews://'); + +done_testing; |