Windows Tests
Greg Ward
greg at gerg.ca
Sat Apr 23 20:22:43 CDT 2011
On 22 April 2011, Matt Mackall said:
> To the extent that these sorts of conversions are mechanical, we
> probably want to figure out how to unify them with our existing .t files
> so we don't need to duplicate everything.
>
> My thought is we can add some new markers to the .t format for
> Windows/Unix-specific commands and responses:
>
> $ hg status
> [U] foo/bar
> [W] foo\bar
>
> [U] $ cat foo
> [W] $ type foo
> This is the contents of foo.
Eek. I just checked the calendar -- you're almost a month late for
April Fool's Day!
Perhaps you chose bad examples: IMHO run-tests.py can and should paper
over simple, obvious, common things like / vs \ and cat vs type.
However, for non-common things, some sort of platform conditional
would be nice.
E.g. anything that does chmod +x and then tests that hg preserves
that would be Unix-only. So do we want syntax like this:
if unix:
$ chmod +x foo
$ hg commit -A
...
or this:
[U] $ chmod +x foo
[U] $ hg commit -A
[U] ...
? Since the test language is simple and line-based, the latter seems
more natural.
--
Greg Ward http://www.gerg.ca/
More information about the Mercurial-devel
mailing list