subversion-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Philip Martin <philip.mar...@wandisco.com>
Subject svnadmin_tests.py 24 and svntest.verify.UnorderedRegexOutput
Date Tue, 04 Oct 2011 19:00:49 GMT
We had a buildbot failure: http://ci.apache.org/builders/bb-openbsd/builds/170

The test locks two files, runs 'svnadmin lslocks' and checks the output
using:

  expected_output = svntest.verify.UnorderedRegexOutput([
      "Path: /A/B/lambda",
      "UUID Token: opaquelocktoken",
      "Owner: jrandom",
      "Created:",
      "Expires:",
      "Comment \(1 line\):",
      "Locking files",
      "Path: /iota",
      "UUID Token: opaquelocktoken.*",      
      "\n", # empty line    
      ])

The "Created:" lines in the svnadmin output include a timestamp and the
test passes when the two locks have the same timestamp, but
occassionally the timestamps differ by one second and the test fails.

This seems to be a problem with our regexp matching. The output has two
identical "Owner" lines and the one "Owner" line in UnorderedRegexOutput
will match both.  The output has two different "UUID" lines and we have
two "UUID" lines in UnorderedRegexOutput, and although either would
match both lines in the output we need to have both "UUID" lines in
UnorderedRegexOutput or the test fails.

A line in UnorderedRegexOutput will match multiple lines in the output
provided the output lines match, but where different output lines match
it will only match one of them.

So it seems we need one "Created:" line in UnorderedRegexOutput when the
two timestamps are the same, but two lines when the timestamps differ.

Are we misusing UnorderedRegexOutput?  How do we fix the test?

-- 
uberSVN: Apache Subversion Made Easy
http://www.uberSVN.com

Mime
View raw message