# Force the test runner to ensure the extension is loaded
!! hooks
poem
!! endhooks

#Regression tests for existing functionality, to ensure nothing was broken.
!! test
<poem>
!! input
<poem>
this
is
a
test
</poem>
!! result

this
is
a
test

!! end

!!test
  <poem> with recursive parsing
!!input
<poem>
this ''is'' a '''test'''
</poem>
!! result

this is a test

!!end

!!test
  <poem> with leading whitespace
!!input
<poem>

   test

</poem>
!! result

   test

!!end

!!test
Horizontal rule
!!input
<poem>
some
-----
text
</poem>
!!result

some

text

!!end

#test for new poem/nowiki feature; should fail without new enhancement.
!! test 2
example of <nowiki> without <poem>
!!options
disabled
!! input
<nowiki>
this
is
a
test
</nowiki>
!! result

this
is
a
test

!! end

!! test
  nested <poem><nowiki>
!! input
<poem><nowiki>
this
is
a
test
</nowiki></poem>
!! result

this
is
a
test

!!end

!! test 5
  nested <poem><nowiki> with formatting
!! input
<poem><nowiki>
this
'''is'''
a
test
</nowiki></poem>
!! result

this
'''is'''
a
test

!! end

!! test
Basic <poem> usage with style
!! input
<poem style="border: 2px solid #d6d2c5; background-color: #f9f4e6; padding: 1em;">
A stately pleasure-dome decree:
Where Alph, the sacred river, ran
Through caverns measureless to man
Down to a sunless sea.
</poem>
!! result

A stately pleasure-dome decree:
Where Alph, the sacred river, ran
Through caverns measureless to man
Down to a sunless sea.

!! end
