Pulling out the toRegex test cases into a data provider.