mirror of
https://github.com/moparisthebest/wget
synced 2024-07-03 16:38:41 -04:00
Add test to ensure correct return code on --post-file failure
Signed-off-by: Darshit Shah <darnir@gmail.com>
This commit is contained in:
parent
50238e49b9
commit
e3b3ea5120
@ -1,3 +1,9 @@
|
|||||||
|
2013-03-12 Darshit Shah <darnir@gmail.com>
|
||||||
|
|
||||||
|
* Makefile.am (EXTRA_DIST): Add Test--post-file.px.
|
||||||
|
* run-px (tests): Likewise.
|
||||||
|
* Test--post-file.px: New file.
|
||||||
|
|
||||||
2012-11-09 Tim Ruehsen <tim.ruehsen@gmx.de>
|
2012-11-09 Tim Ruehsen <tim.ruehsen@gmx.de>
|
||||||
|
|
||||||
* HTTPServer.pm: added check for must-not-match request-header
|
* HTTPServer.pm: added check for must-not-match request-header
|
||||||
|
@ -119,6 +119,7 @@ EXTRA_DIST = FTPServer.pm FTPTest.pm HTTPServer.pm HTTPTest.pm \
|
|||||||
Test-O--no-content-disposition-trivial.px \
|
Test-O--no-content-disposition-trivial.px \
|
||||||
Test-O-nonexisting.px \
|
Test-O-nonexisting.px \
|
||||||
Test-O.px \
|
Test-O.px \
|
||||||
|
Test--post-file.px \
|
||||||
Test-proxied-https-auth.px \
|
Test-proxied-https-auth.px \
|
||||||
Test-proxy-auth-basic.px \
|
Test-proxy-auth-basic.px \
|
||||||
Test-restrict-ascii.px \
|
Test-restrict-ascii.px \
|
||||||
|
23
tests/Test--post-file.px
Executable file
23
tests/Test--post-file.px
Executable file
@ -0,0 +1,23 @@
|
|||||||
|
#!/usr/bin/env perl
|
||||||
|
|
||||||
|
use strict;
|
||||||
|
use warnings;
|
||||||
|
|
||||||
|
use HTTPTest;
|
||||||
|
|
||||||
|
|
||||||
|
###############################################################################
|
||||||
|
|
||||||
|
my $cmdline = $WgetTest::WGETPATH . " -d --post-file=nofile http://localhost:{{port}}/";
|
||||||
|
|
||||||
|
my $expected_error_code = 3;
|
||||||
|
|
||||||
|
|
||||||
|
###############################################################################
|
||||||
|
|
||||||
|
my $the_test = HTTPTest->new (name => "Test-missing-file",
|
||||||
|
cmdline => $cmdline,
|
||||||
|
errcode => $expected_error_code);
|
||||||
|
exit $the_test->run();
|
||||||
|
|
||||||
|
# vim: et ts=4 sw=4
|
@ -70,6 +70,7 @@ my @tests = (
|
|||||||
'Test-O--no-content-disposition-trivial.px',
|
'Test-O--no-content-disposition-trivial.px',
|
||||||
'Test-O-nonexisting.px',
|
'Test-O-nonexisting.px',
|
||||||
'Test-O.px',
|
'Test-O.px',
|
||||||
|
'Test--post-file.px',
|
||||||
'Test-O-nc.px',
|
'Test-O-nc.px',
|
||||||
'Test-restrict-ascii.px',
|
'Test-restrict-ascii.px',
|
||||||
'Test-Restrict-Lowercase.px',
|
'Test-Restrict-Lowercase.px',
|
||||||
|
Loading…
Reference in New Issue
Block a user