t/compilers/pge/p6regex/01-regex.t -- Basic P6 Regex tests


These tests are based on Individual tests are stored in the rx_* files in the same directory; There is one test per line: each test consists of the following columns (separated by one *or more* tabs):


The Perl 6 regex to test.


The string that will be matched against the pattern. Use '' to indicate an empty string.


The expected result of the match. Either y for a successful match, n for a failed one. Otherwise the output is expected to begin and end with /.

This result is used in one of two ways: If an exception is thrown by the match, the result must be contained in the exception's message. If the match succeeds, then the message must be contained in a dump of the match object.

test id

A unique test identifier. This allows us to track TODO/SKIP information in *this* file instead of the associated test file, which lets us easily share the tests across implementations of perl6's regex engine.


Description of the test.


    % prove t/compilers/pge/01-regex.t


Note that while our job would be easier if we could use regular expressions in here, but we want to avoid any dependency on the thing we're testing.

Need to add in test ids, to avoid the precarious line numbering.