View | Details | Raw Unified | Return to bug 18794
Collapse All | Expand All

(-)a/t/db_dependent/OAI/Server.t (-5 / +2 lines)
Lines 82-91 my $get_response = sub { Link Here
82
    $response = XMLin($stdout);
82
    $response = XMLin($stdout);
83
};
83
};
84
$get_response->();
84
$get_response->();
85
my $now = DateTime->now . 'Z';
86
my $expected = {
85
my $expected = {
87
    request => 'http://localhost',
86
    request => 'http://localhost',
88
    responseDate => $now,
89
    xmlns => 'http://www.openarchives.org/OAI/2.0/',
87
    xmlns => 'http://www.openarchives.org/OAI/2.0/',
90
    'xmlns:xsi' => 'http://www.w3.org/2001/XMLSchema-instance',
88
    'xmlns:xsi' => 'http://www.w3.org/2001/XMLSchema-instance',
91
    'xsi:schemaLocation' => 'http://www.openarchives.org/OAI/2.0/ http://www.openarchives.org/OAI/2.0/OAI-PMH.xsd',
89
    'xsi:schemaLocation' => 'http://www.openarchives.org/OAI/2.0/ http://www.openarchives.org/OAI/2.0/OAI-PMH.xsd',
Lines 104-117 my $expected = { Link Here
104
        ],
102
        ],
105
    },
103
    },
106
};
104
};
105
delete $response->{responseDate};
107
is_deeply($response, $expected, "ListMetadataFormats");
106
is_deeply($response, $expected, "ListMetadataFormats");
108
107
109
%param = ( verb => 'ListIdentifiers' );
108
%param = ( verb => 'ListIdentifiers' );
110
$get_response->();
109
$get_response->();
111
$now = DateTime->now . 'Z';
112
$expected = {
110
$expected = {
113
    request => 'http://localhost',
111
    request => 'http://localhost',
114
    responseDate => $now,
115
    xmlns => 'http://www.openarchives.org/OAI/2.0/',
112
    xmlns => 'http://www.openarchives.org/OAI/2.0/',
116
    'xmlns:xsi' => 'http://www.w3.org/2001/XMLSchema-instance',
113
    'xmlns:xsi' => 'http://www.w3.org/2001/XMLSchema-instance',
117
    'xsi:schemaLocation' => 'http://www.openarchives.org/OAI/2.0/ http://www.openarchives.org/OAI/2.0/OAI-PMH.xsd',
114
    'xsi:schemaLocation' => 'http://www.openarchives.org/OAI/2.0/ http://www.openarchives.org/OAI/2.0/OAI-PMH.xsd',
Lines 120-125 $expected = { Link Here
120
        content => "Required argument 'metadataPrefix' was undefined",
117
        content => "Required argument 'metadataPrefix' was undefined",
121
    },
118
    },
122
};
119
};
120
delete $response->{responseDate};
123
is_deeply($response, $expected, "ListIdentifiers without metadaPrefix argument");
121
is_deeply($response, $expected, "ListIdentifiers without metadaPrefix argument");
124
122
125
$dbh->rollback;
123
$dbh->rollback;
126
- 

Return to bug 18794