Generating random strings from a regular expression

For testing purposes it is sometimes useful to create random strings that conform to some specified pattern. For example, you want to create random phone numbers that pass through the validation in your software. One easy way to specify the pattern is to use a regular expression or regex. For our phone numbers, we could specify `555-\d{4]`, for example.

Generating a random string from a regex is not easy to code yourself, but luckily somebody else has already wrote a program that does this. In fact, there are quite a number of tools available that can provide examples for any regular expression. Some of these can even list all possible matches to a regex.

These tools or libraries can create example matches for regular expression patterns:

And here are some recommendations if you don't know which one to choose:

I hope this list can keep people from creating another regex library.