File Coverage

blib/lib/Sah/Schema/multi_line_str.pm
Criterion Covered Total %
statement 3 3 100.0
branch n/a
condition n/a
subroutine 1 1 100.0
pod n/a
total 4 4 100.0


line stmt bran cond sub pod time code
1             package Sah::Schema::multi_line_str;
2              
3 1     1   329489 use strict;
  1         3  
  1         226  
4              
5             our $AUTHORITY = 'cpan:PERLANCAR'; # AUTHORITY
6             our $DATE = '2024-02-06'; # DATE
7             our $DIST = 'Sah-Schemas-Str'; # DIST
8             our $VERSION = '0.018'; # VERSION
9              
10             our $schema = ['str' => {
11             summary => 'A multi-line string',
12             description => <<'MARKDOWN',
13              
14             String cannot be empty or just contain a single line of text; it must contain at
15             least one of either \x0D or \x0A character.
16              
17             MARKDOWN
18             match => qr/[\x0a\x0d]/,
19             examples => [
20             {value=>'', valid=>0},
21             {value=>'a', valid=>0},
22             {value=>"line1\nline2", valid=>1},
23             ],
24             }];
25              
26             1;
27             # ABSTRACT:
28              
29             __END__