[Mono-devel-list] ILBased Regex Engine
Ben Maurer
bmaurer at users.sourceforge.net
Sun Jan 4 21:28:33 EST 2004
On Sun, 2004-01-04 at 10:38, Eric Durand-Tremblay wrote:
> I just finished reading the code of System.Text.RegularExpression. Real
> great work, thanks to the author, it will be really easy to integrate
> the ILBased Engine.
>
> We will soon begin our almost full time work on the project.
> (University instance accepted the project)
This is extremely exciting to hear! I look forward to seeing code from
this! I would love to hear about your design ideas, either on the
mailing list or on IRC.
> I was wondering if some unit test exist for the Regex. In anon-cvs
> source tree only the case of equality is tested.
Specifically for Mono, no. However, there are some other sources:
* Regular Expressions are pretty much standardized, there are very
few differences between implementations. So, what you could do
is find a test suite from another implementation (for example,
Perl, Mozilla's JavaScript, etc.). To filter out cases that MS
does not support, you could make a harness and run it on the MS
runtime. It would print out only the valid tests. Then you
should run those on mono, and they should all work. Depending on
the license of the project from which you take the tests, you
may or may not be able to check the tests into cvs. It would be
best to find at least some that could be checked in. However, it
is also good to make sure you get as many tests as you can, even
if licences do not allow you to check them into CVS.
* I have heard that Rotor has an extensive jscript test suite.
This is likely to include RegEx tests. The license may permit
you to run the test suite on Mono. At first glance, there seems
to be nothing that prohibits that outright. Miguel would have to
comment some more. Obviously, however, you could not check these
into cvs.
Also, there are many sites with repositories of `useful' regex's (eg,
something to check for a valid email, zip code, etc). You could
copy/paste some of these as some initial tests.
You could also make a `smart' computer script that would generate valid
RegEx expressions and random inputs. You could then run that on the MS
runtime, and capture the results. When you run it on Mono, the results
should be the same.
-- Ben
More information about the Mono-devel-list
mailing list