# HG changeset patch # User Mads Kiilerich # Date 1321836560 -3600 # Node ID 8b84d040d9f9ce7736146989a063432d92928abc # Parent 7786b7dfbc4688d2ef639cbf3beedda11e36f940 tests: introduce 'hghave msys' to skip tests that would fail because of msys diff -r 7786b7dfbc46 -r 8b84d040d9f9 tests/hghave --- a/tests/hghave Wed Nov 23 16:35:17 2011 -0600 +++ b/tests/hghave Mon Nov 21 01:49:20 2011 +0100 @@ -221,6 +221,9 @@ def has_tic(): return matchoutput('test -x "`which tic`"', '') +def has_msys(): + return os.getenv('MSYSTEM') + checks = { "baz": (has_baz, "GNU Arch baz client"), "bzr": (has_bzr, "Canonical's Bazaar client"), @@ -255,6 +258,7 @@ "tla": (has_tla, "GNU Arch tla client"), "unix-permissions": (has_unix_permissions, "unix-style permissions"), "windows": (has_windows, "Windows"), + "msys": (has_msys, "Windows with MSYS"), } def list_features(): diff -r 7786b7dfbc46 -r 8b84d040d9f9 tests/test-clone-cgi.t --- a/tests/test-clone-cgi.t Wed Nov 23 16:35:17 2011 -0600 +++ b/tests/test-clone-cgi.t Mon Nov 21 01:49:20 2011 +0100 @@ -1,3 +1,5 @@ + $ "$TESTDIR/hghave" no-msys || exit 80 # MSYS will translate web paths as if they were file paths + This is a test of the wire protocol over CGI-based hgweb. initialize repository diff -r 7786b7dfbc46 -r 8b84d040d9f9 tests/test-newcgi.t --- a/tests/test-newcgi.t Wed Nov 23 16:35:17 2011 -0600 +++ b/tests/test-newcgi.t Mon Nov 21 01:49:20 2011 +0100 @@ -1,3 +1,5 @@ + $ "$TESTDIR/hghave" no-msys || exit 80 # MSYS will translate web paths as if they were file paths + This tests if CGI files from after d0db3462d568 but before d74fc8dec2b4 still work. diff -r 7786b7dfbc46 -r 8b84d040d9f9 tests/test-newercgi.t --- a/tests/test-newercgi.t Wed Nov 23 16:35:17 2011 -0600 +++ b/tests/test-newercgi.t Mon Nov 21 01:49:20 2011 +0100 @@ -1,3 +1,5 @@ + $ "$TESTDIR/hghave" no-msys || exit 80 # MSYS will translate web paths as if they were file paths + This is a rudimentary test of the CGI files as of d74fc8dec2b4. $ hg init test diff -r 7786b7dfbc46 -r 8b84d040d9f9 tests/test-oldcgi.t --- a/tests/test-oldcgi.t Wed Nov 23 16:35:17 2011 -0600 +++ b/tests/test-oldcgi.t Mon Nov 21 01:49:20 2011 +0100 @@ -1,3 +1,5 @@ + $ "$TESTDIR/hghave" no-msys || exit 80 # MSYS will translate web paths as if they were file paths + This tests if CGI files from before d0db3462d568 still work. $ hg init test diff -r 7786b7dfbc46 -r 8b84d040d9f9 tests/test-paths.t --- a/tests/test-paths.t Wed Nov 23 16:35:17 2011 -0600 +++ b/tests/test-paths.t Mon Nov 21 01:49:20 2011 +0100 @@ -1,3 +1,5 @@ + $ "$TESTDIR/hghave" no-msys || exit 80 # MSYS will translate /foo/bar as if it was a real file path + $ hg init a $ hg clone a b updating to branch default diff -r 7786b7dfbc46 -r 8b84d040d9f9 tests/test-push-cgi.t --- a/tests/test-push-cgi.t Wed Nov 23 16:35:17 2011 -0600 +++ b/tests/test-push-cgi.t Mon Nov 21 01:49:20 2011 +0100 @@ -1,3 +1,5 @@ + $ "$TESTDIR/hghave" no-msys || exit 80 # MSYS will translate web paths as if they were file paths + This is a test of the push wire protocol over CGI-based hgweb. initialize repository diff -r 7786b7dfbc46 -r 8b84d040d9f9 tests/test-revset.t --- a/tests/test-revset.t Wed Nov 23 16:35:17 2011 -0600 +++ b/tests/test-revset.t Mon Nov 21 01:49:20 2011 +0100 @@ -1,3 +1,5 @@ + $ "$TESTDIR/hghave" no-msys || exit 80 # MSYS will translate /a/b/c/ as if it was a real file path + $ HGENCODING=utf-8 $ export HGENCODING