X-Git-Url: http://git.vanrenterghem.biz/git.ikiwiki.info.git/blobdiff_plain/d42ed9bdc3e4c4875e6fcf2f5e5ffe71652a51ee..b63f1260eef70cf7eb1703ebae1244db7cef0583:/t/meta.t?ds=sidebyside diff --git a/t/meta.t b/t/meta.t old mode 100644 new mode 100755 index ab25c2f83..d23d9bc71 --- a/t/meta.t +++ b/t/meta.t @@ -8,10 +8,21 @@ my $tmp = 't/tmp'; my $srcdir = "$tmp/in"; my $destdir = "$tmp/out"; -my @command = (qw(./ikiwiki.out --plugin meta --disable-plugin htmlscrubber)); -push @command, qw(-underlaydir=underlays/basewiki); -push @command, qw(-set underlaydirbase=underlays); -push @command, qw(--templatedir=templates); +my $installed = $ENV{INSTALLED_TESTS}; + +my @command; +if ($installed) { + @command = qw(ikiwiki); +} +else { + ok(! system("make -s ikiwiki.out")); + @command = qw(perl -I. ./ikiwiki.out + --underlaydir=underlays/basewiki + --set underlaydirbase=underlays + --templatedir=templates); +} + +push @command, qw(--plugin meta --disable-plugin htmlscrubber); push @command, $srcdir, $destdir; sub write_build_read_compare { @@ -125,12 +136,11 @@ write_build_read_compare( # qr{}, #); -# XXX buggy? is this my bug? maybe twitter:foo would just work if this worked -#write_build_read_compare( -# 'name', -# q{[[!meta name="thingy" value1="hi" value2="hello"]]}, -# qr{}, -#); +write_build_read_compare( + 'name', + q{[[!meta name="thingy" value1="hi" value2="hello"]]}, + qr{}, +); write_build_read_compare( 'keywords', @@ -149,11 +159,11 @@ write_build_read_compare( # '[[!meta twitter:card="player"]]', # qr{}, #); -# -#write_build_read_compare( -# 'twittercard2', -# '[[!meta name="twitter:card" content="player"]]', -# qr{}, -#); + +write_build_read_compare( + 'twittercard2', + '[[!meta name="twitter:card" content="player"]]', + qr{}, +); done_testing();