diff options
author | Joey Hess <joey@gnu.kitenet.net> | 2010-02-11 20:39:10 -0500 |
---|---|---|
committer | Joey Hess <joey@gnu.kitenet.net> | 2010-02-11 20:39:10 -0500 |
commit | c923e0ba3377f85107ccea1933a042aaec675c77 (patch) | |
tree | dd185a72ba4b63a171fd68cb2342ae64c8e73788 /t | |
parent | 7af18f2a1ec8b5ce4764813b0464112f517e806f (diff) |
Allow globs to be used in user() pagespecs.
Diffstat (limited to 't')
-rwxr-xr-x | t/pagespec_match.t | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/t/pagespec_match.t b/t/pagespec_match.t index b96947407..197ff818b 100755 --- a/t/pagespec_match.t +++ b/t/pagespec_match.t @@ -1,7 +1,7 @@ #!/usr/bin/perl use warnings; use strict; -use Test::More tests => 64; +use Test::More tests => 70; BEGIN { use_ok("IkiWiki"); } @@ -40,6 +40,13 @@ ok(! pagespec_match("foo", "foo and bar"), "foo and bar"); ok(pagespec_match("{f}oo", "{*}*"), "curly match"); ok(! pagespec_match("foo", "{*}*"), "curly !match"); +ok(pagespec_match("somepage", "user(frodo)", user => "frodo")); +ok(pagespec_match("somepage", "user(frodo)", user => "Frodo")); +ok(! pagespec_match("somepage", "user(frodo)", user => "Sam")); +ok(pagespec_match("somepage", "user(*o)", user => "Bilbo")); +ok(pagespec_match("somepage", "user(*o)", user => "frodo")); +ok(! pagespec_match("somepage", "user(*o)", user => "Sam")); + # The link and backlink stuff needs this. $config{userdir}=""; $links{foo}=[qw{bar baz}]; |