-# CGI wrapper should be exactly the requested mode
-my (undef, undef, $mode, undef, undef,
- undef, undef, undef, undef, undef,
- undef, undef, undef) = stat("t/tmp/ikiwiki.cgi");
-is($mode & 07777, 0754);
+sub check_cgi_mode_bits {
+ my (undef, undef, $mode, undef, undef,
+ undef, undef, undef, undef, undef,
+ undef, undef, undef) = stat("t/tmp/ikiwiki.cgi");
+ is($mode & 07777, 0754);
+}
+
+#######################################################################
+# site 1: a perfectly ordinary ikiwiki
+
+write_setup_file(
+ html5 => 0,
+ url => "http://example.com/wiki/",
+ cgiurl => "http://example.com/cgi-bin/ikiwiki.cgi",
+);
+thoroughly_rebuild();
+check_cgi_mode_bits();