gap-packages / anupq

The ANUPQ GAP package
https://gap-packages.github.io/anupq/
Artistic License 2.0
4 stars 6 forks source link

Filter out timings in .tst files #63

Open fingolfin opened 2 years ago

fingolfin commented 2 years ago

Right now tst/anupq1eg.tst contains this:

gap> phi := EpimorphismStandardPresentation( procId : ClassBound := 3 );
#I  Class 1 3-quotient and its 3-covering group computed in 0.00 seconds
#I  Order of GL subgroup is 48
#I  No. of soluble autos is 0
#I    dim U = 1  dim N = 3  dim M = 3
#I    nice stabilizer with perm rep
#I  Computing standard presentation for class 2 took 0.00 seconds
#I  Computing standard presentation for class 3 took 0.00 seconds

Note the three timings in there.

They can cause this test to fail due to random fluctuations on the test system. In practice this luckily seems to happen veeery rarely, but it just did in this PackageDistro CI run

Theses messages are printed by the pq binary. One way to fix the problem would be to patch the binary to not print them. However, presumably some people may find them useful...

So another way to deal with it would be to use the TestDirectory option testOptions to override the Test option compareFunction with a function that ignores the timing bit (say by searching substrings matching "took ?.?? seconds" and replacing them by "took 0.00 seconds").