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

(-)a/Koha/Exceptions/Metadata.pm (-1 / +1 lines)
Lines 36-42 sub full_message { Link Here
36
36
37
    unless ($msg) {
37
    unless ($msg) {
38
        if ( $self->isa('Koha::Exceptions::Metadata::Invalid') ) {
38
        if ( $self->isa('Koha::Exceptions::Metadata::Invalid') ) {
39
            $msg = sprintf( "Invalid data, cannot decode object (id=%s, biblionumber=%s, format=%s, schema=%s, decoding_error='%s')",
39
            $msg = sprintf( "Invalid data, cannot decode metadata object (biblio_metadata.id=%s, biblionumber=%s, format=%s, schema=%s, decoding_error='%s')",
40
                $self->id, $self->biblionumber, $self->format, $self->schema, $self->decoding_error );
40
                $self->id, $self->biblionumber, $self->format, $self->schema, $self->decoding_error );
41
        }
41
        }
42
    }
42
    }
(-)a/t/Koha/Exceptions.t (-2 / +1 lines)
Lines 123-129 subtest 'Koha::Exceptions::Metadata tests' => sub { Link Here
123
        'Exception is thrown :-D';
123
        'Exception is thrown :-D';
124
124
125
    # stringify the exception
125
    # stringify the exception
126
    is( "$@", 'Invalid data, cannot decode object (id=an_id, biblionumber=a_biblionumber, format=a_format, schema=a_schema, decoding_error=\'a_nasty_error\')', 'Exception stringified correctly' );
126
    is( "$@", 'Invalid data, cannot decode metadata object (biblio_metadata.id=an_id, biblionumber=a_biblionumber, format=a_format, schema=a_schema, decoding_error=\'a_nasty_error\')', 'Exception stringified correctly' );
127
127
128
    throws_ok
128
    throws_ok
129
        { Koha::Exceptions::Metadata::Invalid->throw( "Manual message exception" ) }
129
        { Koha::Exceptions::Metadata::Invalid->throw( "Manual message exception" ) }
130
- 

Return to bug 26171