add test for main regexAsString function