Skip to content

sihlfall/regex-test-cases

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Regular expression test cases

Intended for the testing of regular expression engines.

Extracted from the log output of the tests accompanying the RE2 regex engine.

JSON layouts:

test-cases/*.json:

{
    "name": <name of suite the test case belongs to>,
    "strs": [ <strings to test against> ],
    "regexs": [ <regular expressions to test> ]
}


test-results/re2/*.json:

[ for each of regexs
    [ for each of strs
        [
            [ <result of re2, anchored at start and end> ],
            [ <result of re2, unanchored> ],
            [ <result of re_longest, anchored at start and end> ],
            [ <result of re_longest, unanchored> ]
        ]
    ]
]
with the [ <result ...> ] arrays being arrays of integers,
    with -1 meaning "no value",
    with arrays containing only -1's being replaced by []

RE2 version used:

Commit 03da4fc0857c285e3a26782f6bc8931c4c950df4.

About

Regex engine test cases extracted from RE2

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published