Commit Graph

20 Commits

Author SHA1 Message Date
Matt Mackall
36234f5a00 tests: add repository check for pyflakes test
If this test was run from a tarball with no Mercurial repository, it
would fail because 'hg manifest' didn't work.
2014-05-01 09:42:23 -05:00
Matt Mackall
eb09e501b5 tests: fix unused imports from inotify removal caught by pyflakes 2014-03-04 09:56:59 -06:00
Matt Mackall
66c8bd54e8 extensions: remove the inotify extension (BC)
This extension has always had correctness issues and has been
unmaintained for years. It is now removed in favor of the third-party
hgwatchman which is maintained and appears to be correct.

Users with inotify enabled in their config files will fall back to
standard status performance.
2014-03-01 16:20:15 -06:00
Mads Kiilerich
59b97fe104 tests: ignore http tests that are known wontfix failures on python 2.4
As mentioned on http://bz.selenic.com/show_bug.cgi?id=2739#c17 , babf177f9036
left test-http.t failing on Python < 2.4.3. That has not been noticed because
most 2.4 testing has been done with a patched 2.4.2.

This makes sure that the tests only are run for Python >= 2.4.3. That makes it
possible to verify that everything else works with Python 2.4.
2014-02-05 01:37:37 +01:00
Mads Kiilerich
5be7383671 tests: 'hghave tic' also requires curses support in Python
test-status-color.t would fail when using a Python without curses.
2014-01-20 01:29:54 +01:00
Simon Heimberg
2f030231df tests: fix hghave root on windows
This lets tests\test-hghave.t pass on windows where geteuid does not exist.
2013-11-23 01:06:20 +01:00
Matt Mackall
280eec0087 tests: skip tests that require not having root (issue4089)
This adds a new root hghave to test against. Almost all of these are a
subset of unix-permissions, but that is also used for checking exec
bit handling.
2013-11-14 18:07:43 -06:00
FUJIWARA Katsunori
aa64a2119a hghave: add "py3k" feature to check whether test runs with Python 3.x
This patch adds "py3k" feature to check whether test runs with Python
3.x.

This check is needed for portability of test code: for example, in the
default, modules are imported relatively first with python 2.x, but
imported absolutely with Python 3.x.
2013-10-05 01:02:22 +09:00
FUJIWARA Katsunori
c46519c9ab hghave: add "absimport" feature to check "absolute_import" in __future__
This patch adds "absimport" feature to check whether "absolute_import"
exists in __future__, which means supporting module loading by
absolute name.

This check is needed for portability of test code using
"absolute_import", because Python earlier than 2.5 doesn't support it.
2013-10-05 01:02:22 +09:00
Simon Heimberg
6059e06d0f cleanup: drop unused variables and an unused import 2013-07-01 20:48:56 +02:00
Jim Hague
3d040369cd tests: AIX can't handle negative date in test-dirstate.t
test-dirstate.t fails on AIX in the absurd date test. AIX touch errors on
any date prior to 1970. AIX mktime() gives an error on such dates, so the
problem is deeper than touch and attempts to work around touch in Python
failed.

Give up. Add an AIX test to hghave and skip the absurd date test on AIX.
2013-04-30 14:56:33 +01:00
Bryan O'Sullivan
8b517d42bc hghave: introduce a test (unused) for cvs >= 1.12 2013-01-09 13:16:54 -08:00
Thomas Arendsen Hein
024d25472d subrepo, hghave: use "svn --version --quiet" to determine version number
svn --version --quiet is implemented since svn 0.14.1 (August 2002)
and prints just the version number, not the long output (21 lines)
of "svn --version".

Additionally I expect this output format to be more stable, at least
it is not changed with different translations.
2012-10-04 16:52:20 +02:00
Patrick Mezard
622b756249 test-http-branchmap: enable on Windows
Tests using "hg serve --daemon" are currently disabled on Windows for
lack of proper kill utility. The one shipped with MinGW operates on
internal process identifiers and not on the ones recorded by hg serve.
Fortunately we can replace most of them by calls to killdaemons.py.

This patch is a proof of concept on how to run these tests on Windows.
The plan is:
- Check test-http-branchmap.t does not fail/hang on the buildbot
- Convert all kill utility calls to killdaemons.py calls.
- Add a rule in check-code.py to forbid kill calls, or ignore the
  remaining ones (test-hup.t, etc.).
- Possibly drop the 'serve' rule from hghave.

The:

  listening at http://*:$HGPORT1/

line does not appear on Windows because the detached process can no
longer write on its parent streams. Grepping hg serve stdout directly
causes the parent process to never return and hangs the test. This is a
bug, but I have no simple solution and prefer to pay this small price
and enable hg serve tests on Windows.
2012-09-09 12:31:14 +02:00
Mads Kiilerich
490f13d607 tests: hghave outer-repo should be true even if a bad repo is found
Only the abort message 'no repository found' is a reliable indication that
there is no outer repo.
2012-06-20 23:41:21 +02:00
Mads Kiilerich
bf6fb79f83 tests: introduce hghave hardlinks
Some tests can't be run on FAT filesystems because it doesn't support
hardlinks.
2012-06-15 00:02:27 +02:00
Mads Kiilerich
c909f8280c tests/hghave: test that the inotify unix socket actually can be created
Inotify do not work on FAT filesystems.
2012-06-15 00:02:27 +02:00
Mads Kiilerich
395b2875e3 tests/hghave: test that a fifo actually can be created on the filesystem
Some tests were failing on FAT filesystems.
2012-06-15 00:02:27 +02:00
Mads Kiilerich
266857283d tests/hghave: consistently use dir='.', prefix=tempprefix for tempfiles
Some feature tests were done in the wrong directory and could thus give the
wrong result.
2012-06-15 00:02:27 +02:00
Adrian Buehlmann
c74860921b tests/hghave: extract hghave.py
hghave is degraded to a bare script, moving the functions to hghave.py
so they can be shared later on.
2012-06-14 12:54:54 +02:00