Test suite failures in IDFILE tests if backslash in TMP path
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Testrepository |
Fix Released
|
Critical
|
Robert Collins |
Bug Description
Due to the way pseudo-envvar substitution is done on the test command configuration, inputs containing a backslash may be mangled. Given Windows uses backslash as a directory separator, this is a particular problem there:
re.
If the path contains a backslash followed by a number instead of just 't' then `sre_constants.
The problem is fixed in r113.1.4 but this part of the lp:~gz/testrepository/misc_workarounds branch was not merged. Apparently fixing this interferes with the idea of embedding shell scripts into the configuration files as requested for bug 595295 but I can't for the life of me see how (or why that should be encouraged).
On my box, the test suite has the following two failures because of this:
=======
FAIL: testrepository.
-------
Text attachment: traceback
------------
Traceback (most recent call last):
...
File "...\testreposi
], ui.outputs)
...
AssertionError: Match failed. Matchee: ...
Matcher: Equals(...)
Difference: !=:
reference = [('values',
[('running', 'foo --load-list b:\\temp\
('popen',
('foo --load-list b:\\temp\
{'shell': True, 'stdout': -1, 'stdin': -1}),
('results', *),
('values', [('id', 1), ('tests', 0)])]
actual = [('values', [('running', 'foo --load-list b:\temp\
('popen',
('foo --load-list b:\temp\
{'shell': True, 'stdin': -1, 'stdout': -1}),
('results', <testrepository
('values', [('id', 1), ('tests', 0)])]
------------
=======
FAIL: testrepository.
-------
Text attachment: traceback
------------
Traceback (most recent call last):
...
File "...\testreposi
le_setting
self.
...
AssertionError: Match failed. Matchee: "foo --load-list b: emp mp_s0nwu"
Matcher: Equals('foo --load-list b:\\temp\
Difference: !=:
reference = 'foo --load-list b:\\temp\
actual = 'foo --load-list b:\temp\tmp_s0nwu'
------------
There is a wider problem with treating string configuration as shell script, in particular spaces other significant characters are passed through unescaped, which may also cause these tests to fail under some setups.
Changed in testrepository: | |
status: | In Progress → Fix Committed |
Changed in testrepository: | |
status: | Fix Committed → Fix Released |
The feature isn't about embedding shell /scripts/ its about being able to control whats run via shell -variables-. Thats a reasonable and very useful facility, but it only works on unices today.