Uploaded image for project: 'Xerces-C++'
  1. Xerces-C++
  2. XERCESC-2153

Tests can fail on Windows when run in parallel



    • Wish
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 3.2.1
    • 3.2.2
    • Samples/Tests
    • Windows 10 x64 with VS2017 x64 build of Xerces-C++ 3.2.2 prerelease.


      Tests always pass when run serially, so I don't see this as a blocker for 3.2.2 unless it's indicative of a very long-standing problem internally in Xerces rather than that the tests were not originally written with parallel execution in mind.

      When running "ctest -jn" to run tests in parallel, tests can randomly fail.  Looks like an interaction between tests when run at the same time.  Some resource contention?

      The following is a reduced testcase, where I've found two tests which interact badly (there may be others).  Both are using personal.xml as input.

      D:\xerces-c-3.2.2\b>ctest -C Release -j 4 -R "DOMPrint3|StdInParse2"
      Test project D:/xerces-c-3.2.2/b
      {{ Start 66: DOMPrint3}}
      {{ Start 70: StdInParse2}}
      1/2 Test #66: DOMPrint3 ........................***Failed 0.07 sec
      2/2 Test #70: StdInParse2 ...................... Passed 0.08 sec50% tests passed, 1 tests failed out of 2Total Test time (real) = 0.11 secThe following tests FAILED:
      {{ 66 - DOMPrint3 (Failed)}}
      Errors while running CTest

      I can't reproduce on Linux, so it may well be Windows-specific due to file locking preventing multiple readers of a file?  Is it due to one process having it held open on stdin while the other tries to open it.  Running multiple StdInParse[123] tests or multiple DOMPrint[123] tests does not result in failure.  But when the two are combined, it's always DOMPrint that fails; is it the open mode being used?




            rleigh Roger Leigh
            rleigh Roger Leigh
            0 Vote for this issue
            2 Start watching this issue