in reply to Re^2: Regex::Reverse tricky test cases
in thread Regex::Reverse tricky test cases

I can't find your module. I can write tests for you, but not without access to your module and its interface.


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.

Replies are listed 'Best First'.
Re^4: Regex::Reverse tricky test cases
by Roy Johnson (Monsignor) on May 17, 2005 at 15:29 UTC
    As yet, it's not a module, it's just a program (and it almost certainly will not become a module, as the difficulties I had not recognized initially are substantial). It was not unexpected that I would find, once the real problems with reversal were pointed out, that they were over my head. But I wanted to understand the problem.

    If you are inclined to write tests for this, they would just be pairs: a regex and what it should reverse to.


    Caution: Contents may have been coded under pressure.

      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.