~ubuntu-branches/ubuntu/trusty/wget/trusty-updates

« back to all changes in this revision

Viewing changes to tests/Test-ftp-iri-recursive.px

  • Committer: Bazaar Package Importer
  • Author(s): Marc Deslauriers
  • Date: 2009-12-12 08:15:59 UTC
  • mfrom: (2.1.5 squeeze)
  • Revision ID: james.westby@ubuntu.com-20091212081559-mvccl4kzdqb138y3
Tags: 1.12-1.1ubuntu1
* Merge from debian testing, remaining changes:
  - Add wget-udeb to ship wget.gnu as alternative to busybox wget
    implementation.
* Keep build dependencies in main:
  - debian/control: remove info2man build-dep
  - debian/patches/00list: disable wget-infopod_generated_manpage.dpatch

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/usr/bin/perl
 
2
 
 
3
use strict;
 
4
use warnings;
 
5
 
 
6
use WgetFeature qw(iri);
 
7
use FTPTest;
 
8
 
 
9
 
 
10
###############################################################################
 
11
 
 
12
my $ccedilla_l1 = "\xE7";
 
13
my $ccedilla_u8 = "\xC3\xA7";
 
14
 
 
15
my $francais = <<EOF;
 
16
Some text.
 
17
EOF
 
18
 
 
19
$francais =~ s/\n/\r\n/;
 
20
 
 
21
# code, msg, headers, content
 
22
my %urls = (
 
23
    "/fran${ccedilla_l1}ais.txt" => {
 
24
        content => $francais,
 
25
    },
 
26
);
 
27
 
 
28
my $cmdline = $WgetTest::WGETPATH . " --local-encoding=iso-8859-1 -r -nH -S ftp://localhost:{{port}}/";
 
29
 
 
30
my $expected_error_code = 0;
 
31
 
 
32
my %expected_downloaded_files = (
 
33
    "fran${ccedilla_l1}ais.txt" => {
 
34
        content => $francais,
 
35
    },
 
36
);
 
37
 
 
38
###############################################################################
 
39
 
 
40
my $the_test = FTPTest->new (name => "Test-ftp-iri-recursive",
 
41
                             input => \%urls,
 
42
                             cmdline => $cmdline,
 
43
                             errcode => $expected_error_code,
 
44
                             output => \%expected_downloaded_files);
 
45
exit $the_test->run();
 
46
 
 
47
# vim: et ts=4 sw=4
 
48