Commit Graph

7 Commits

Author SHA1 Message Date
Yuya Nishihara
9172766ed5 extdata: abort if external command exits with non-zero status (BC)
Per the last discussion, this is more reliable and consistent way than
suppressing an error. For grep, erroring out might be inconvenient, but
for curl, non-zero exit status should be detected. The latter wouldn't be
possible if non-zero status is ignored.

https://www.mercurial-scm.org/pipermail/mercurial-devel/2017-October/105727.html
2017-10-01 12:21:50 +01:00
Matt Harbison
d2dab77cb0 tests: add a substitution for ENOENT/ERROR_FILE_NOT_FOUND messages
Automatic replacement seems better than trying to figure out a check-code rule.
I didn't bother looking to see why the error message and file name is reversed
in the annotate and histedit tests, based on Windows or not.

I originally had this as a list of tuples, conditional on the platform.  But
there are a couple of 'No such file or directory' messages emitted by Mercurial
itself, so unconditional is required for stability.  There are also several
variants of what I assume is 'connection refused' and 'unknown host' in
test-clone.t and test-clonebundles.t for Docker, FreeBSD jails, etc.  Yes, these
are handled by (re) tags, but maybe it would be better to capture those strings
in order to avoid whack-a-mole in future tests.  All of this points to using a
dictionary containing one or more strings-to-be-replaced values.
2017-12-02 19:33:34 -05:00
Matt Harbison
773c9a551d test-extdata: conditonalize error message for Windows 2017-10-14 00:20:59 -04:00
Yuya Nishihara
a92ecdf646 extdata: show debug message if external command exits with non-zero status
This isn't fatal because it's quite common for grep to exit with 1. Thanks to
Foozy for spotting this.
2017-10-01 12:21:50 +01:00
Yuya Nishihara
810071518d extdata: ignore ambiguous identifier as well 2017-10-01 11:56:41 +01:00
Yuya Nishihara
a5c1e61fda templater: add experimental support for extdata
This is minimal and non-controversial implementation of extdata() template
function. Originally extdata sources were exposed to the keyword namespace,
but I've changed it to a plain function for simplicity.
2017-10-01 11:13:09 +01:00
Yuya Nishihara
235c46722f revset: add experimental support for extdata
This is minimal and non-controversial implementation of extdata() revset.
Originally extdata sources were exposed to the symbol namespace, but I've
changed it to a plain function for simplicity.
2017-10-01 10:50:00 +01:00