File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 33use strict;
44use Test qw( plan ok) ;
55
6- plan tests => 127 ;
6+ plan tests => 129 ;
77
88use HTML::Form;
99
@@ -595,3 +595,33 @@ $f = HTML::Form->parse(<<EOT, "http://www.example.com");
595595</form>
596596EOT
597597ok(@warn , 0);
598+
599+ $f = HTML::Form-> parse(<<EOT , base => " http://localhost/" );
600+ <form method=post>
601+ <form action="test" method="post">
602+ <button type="submit" name="submit" value="go">run</button>
603+ </form>
604+ EOT
605+
606+ ok($f -> click-> as_string, <<EOT );
607+ POST http://localhost/
608+ Content-Length: 9
609+ Content-Type: application/x-www-form-urlencoded
610+
611+ submit=go
612+ EOT
613+
614+ $f = HTML::Form-> parse(<<EOT , base => " http://localhost/" );
615+ <form method=post>
616+ <form action="test" method="post">
617+ <button type="submit" name="submit">run</button>
618+ </form>
619+ EOT
620+
621+ ok($f -> click-> as_string, <<EOT );
622+ POST http://localhost/
623+ Content-Length: 7
624+ Content-Type: application/x-www-form-urlencoded
625+
626+ submit=
627+ EOT
You can’t perform that action at this time.
0 commit comments