File: 01.basic.t

package info (click to toggle)
libre-engine-re2-perl 0.18%2Bds-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 440 kB
  • sloc: cpp: 270; perl: 80; makefile: 2; sh: 1
file content (19 lines) | stat: -rw-r--r-- 336 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
use strict;
use Test::More tests => 7;
use re::engine::RE2;

ok("Hello, world" !~ /Goodbye, world/);
is($1, undef);

ok("Hello, world" =~ /Hello, (world)/);
is($1, 'world');

is qr/(Hello), (world)/->number_of_capture_groups, 2;

no re::engine::RE2;
is(eval '"Hello, world" =~ /^(?!Hello).*, (world)/', '');

if (fork) {
    ok(1);
}