That's not how I was thinking of writing tests. More like I would come up with a series of regexes on a static string, then compare the match with the match created by your 'reverse' application. If they match the same, then your app is working. That would narrow down what kind of regexes your app has issues with -- the way of testing you suggest is less useful, because you have to trust that I'm right. ;-)
The Eightfold Path: 'use warnings;', 'use strict;', 'use diagnostics;', perltidy, CGI or CGI::Simple, try the CPAN first, big modules and small scripts, test first.