Catmandu::Validator::Mock(3pm)

Catmandu::Validator::Mock3pm

Validate items based on a flag

Usage

    use Catmandu::Validator::Mock;
    my $validator = Catmandu::Validator::Mock->new(
        message  => 'item is invalid',
        reject   => 1,
    );

Overview

This Catmandu::Validator can be used for testing as it does not actually look at the data to validate. Instead it rejects items if "reject" is set to a true value.

Configuration

message

Error message to return for rejected items.

reject

The validator marks all items as invalid as long as this flag is true. Default is false.

Releases

4 releases since Debian 10 (Buster); the text changed 3 times.

  1. 10
  2. 11
  3. 12
  4. 13

From libcatmandu-perl 1.2024-1 in Debian 13 (Trixie). Parsed by carta from the page's man source.