usemod-options.t 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. # Copyright (C) 2006, 2007 Alex Schroeder <alex@emacswiki.org>
  2. #
  3. # This program is free software; you can redistribute it and/or modify
  4. # it under the terms of the GNU General Public License as published by
  5. # the Free Software Foundation; either version 3 of the License, or
  6. # (at your option) any later version.
  7. #
  8. # This program is distributed in the hope that it will be useful,
  9. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. # GNU General Public License for more details.
  12. #
  13. # You should have received a copy of the GNU General Public License
  14. # along with this program. If not, see <http://www.gnu.org/licenses/>.
  15. require './t/test.pl';
  16. package OddMuse;
  17. use Test::More tests => 7;
  18. add_module('usemod.pl');
  19. InitVariables();
  20. $UseModSpaceRequired = 0;
  21. $UseModMarkupInTitles = 1;
  22. run_tests(split('\n',<<'EOT'));
  23. *one\n**two
  24. <ul><li>one<ul><li>two</li></ul></li></ul>
  25. #one\n##two
  26. <ol><li>one<ol><li>two</li></ol></li></ol>
  27. :one\n:two\n::one and two\n::two and three\n:three
  28. <dl class="quote"><dt /><dd>one</dd><dt /><dd>two<dl class="quote"><dt /><dd>one and two</dd><dt /><dd>two and three</dd></dl></dd><dt /><dd>three</dd></dl>
  29. ;one:eins\n;two:zwei
  30. <dl><dt>one</dt><dd>eins</dd><dt>two</dt><dd>zwei</dd></dl>
  31. =='''title'''==
  32. <h2><strong>title</strong></h2>
  33. 1 \+ 1 = 2
  34. 1 \+ 1 = 2
  35. EOT
  36. xpath_run_tests(split('\n',<<'EOT'));
  37. ==[[Free Link]]==
  38. //h2/text()[string()="[[Free_Link"]/following-sibling::a[@class="edit"][@title="Click to edit this page"][@href="http://localhost/test.pl?action=edit;id=Free_Link"][text()="?"]/following-sibling::text()[string()="]]"]
  39. EOT