Source

hgsubversion / tests / test_util.py

Author Commit Message Labels Comments Date
Siddharth Agarwal
test_util: fix up i18n monkeypatch for Mercurial 3.2 Mercurial rev 0d0350cfc7ab changed the API a bit.
Siddharth Agarwal
test_util: use compat hack for filectxfn for deleted files
David Schleimer
editor: correctly import symlink copy+modify with non-empty prefix We alwasy fail editing for symlinks, since we strip the leading 'link ' subversion includes when storing in mercurial, and then let svn attempt to apply deltas against the stripped version. This unsurprisingly fails, and we write the resulting empty-string to the Filestore for the current revision, and add the symlink in question to the missing list to handle stupidly later. Unfortunately, this …
David Schleimer
editor: correctly import copies of directories from non-tracked or closed branches
Sean Farley
test_util: call makememfilectx
Dan Villiom Podlaski Christiansen
push: fix obsolete feature detection The obsolete feature detection didn't work with demandimport, breaking hgsubversion when running against 2.0-2.3.
Greg Ward
layouts: fix crash when importing hgsubversion itself (issue #402) Mercurial extensions are a bit weird: they aren't normally in sys.path, so you can't assume that "import hgsubversion" works. Luckily, Mercurial sneaks a little treat into sys.modules so that "import hgext_hgsubversion" does work. In fact, to get things working *as a Mercurial extension*, all that's needed is that trivial change to two import lines, in layouts/detect.py and layouts/standard.py. U…
David Schleimer
layouts: add custom layout for those of us that need weird mappings This adds a config-driven custom layout, targeted at the case where you need to fetch a small subset of a large number of subversion branches, or where your subversion layout doesn't match the standard trunk/branches/tags layout very well.
Comments 1
Dan Villiom Podlaski Christiansen
test_util: include Subversion revision when drawing a pretty graph
David Schleimer
tests: cd to tempdir during setUp Since we were running hg clone from the hgsubversion repo, we would often pick up config settings from hgsubversion/.hg/hgrc, including loading extensions. This caused tests to fail for me when they asserted that obsolete is disabled because I have evolve enabled in my hgsubversion checkout. This was probably decreasing the overall stability of the test suite as well, since it meant that clones …
Augie Fackler
test_util: fix missing message in SkipTest raise
Dan Villiom Podlaski Christiansen
tests: remove ability to toggle stupidity on less than class level
Dan Villiom Podlaski Christiansen
tests: add a metaclass for triggering stupid on a class level We use a metaclass similar to the tests for obsolete mode. This metaclass deliberately duplicates each test for each mode; enabling both means that each test function is run four times. This makes it less likely that a fix is accidentally applied to replay mode only, as new tests will often automatically cover both modes. However, as certiain features remain deliberately unimplemented in stupid m…
Dan Villiom Podlaski Christiansen
tests: add a metaclass for testing obsolete mode We use a metaclass to both make the test code more concise, and more likely to cover all cases. Typically, someone adding a new fixes will also add a test, and put it in a class containing similar tests. Going forward, having that entire class automatically then duplicate its methods for relevant modes is a plus; a similar approach for stupid mode already found a few omissions.
Dan Villiom Podlaski Christiansen
tests: count revisions explicitly The assumption that len(repo) corresponds to the count of actual, usable revision in the repository fails in presence of hidden revisions. Instead, we use a dedicated method in test_util, and change all tests to use this for obtaining repository length -- just to be safe...
Dan Villiom Podlaski Christiansen
tests: assert that fetches actually succeed
Dan Villiom Podlaski Christiansen
tests: fix syntax incompatible with Python 2.4
David Schleimer
testutil: clear rcpath when we update HGRCPATH env var hg maintains a global cache of the HGRCPATH that doesn't get updated when HGRCPATH is changed. Nuke said global cache when we change the HGRCPATH.
Augie Fackler
test_util: specify a username in our test-run hgrc.
Patrick Mézard
stupid: do not close branch upon branch-wide revert Reverting a branch with a remove followed by a copy results in a branch replacement. By default, branch replacements are handled by closing the replaced branch and committing the new branch on top of it. But we do not really want that when reverting a branch, we only want a linear history with a changeset capturing the revert.
Patrick Mézard
pull: add hgsubversion.filestoresize to control memory consumption The configuration entry defines the size of the replay or stupid edited file store, that is the maximum amount of edited files data in megabytes which can be kept in memory before falling back to storing it in a temporary directory. Default to 200 (megabytes), use -1 to disable.
Patrick Mézard
Fix more peer breakage with old hg versions
Patrick Mézard
test_util: make repourl() return upper-cased drive letters The SWIG bindings return local svn URLs with upper-case drive letters. Doing the same in repourl() makes the svn info tests URLs match on Windows.
Augie Fackler
Merge hg 2.3 fixes from bos.
Bryan O'Sullivan
tests: fix regressions introduced by peer classes in hg 2.3
ronvoe
Honor SVN auto-props (solves issue #186) The auto-props are read from the users subversion configuration file (~/.subversion/config on posix). System-wide configuration files are not taken into account. The implementation completely bypasses the subversion bindings, because the current bindings provide little support for this functionality.
David Schleimer
Ignore invalid utf8 in commit messages Old svn allowed users to include invalid utf8 in their commits. Since there are real repos with said invalid utf8, we need to be able to import them, even if svn won't.
Bryan O'Sullivan
pull: add a hgsubversion.unsafeskip option to omit unwanted revs
Dan Villiom Podlaski Christiansen
allow Python 2.7 to show medium-size multiline diffs when tests fail
David Schleimer
Partial metadata rebuilding For highly active subversion repositories, it can be excruciatingly slow to pull updates one at a time from subversion. One way around this is to setup another mercurial repo that pulls new commits from svn periodicly (say every 5 minutes). When you want to update your repository, you can pull commits from this mercurial repository via native mercurial protocols, which will be much faster than p…
  1. Prev
  2. 1
  3. 2
  4. 3
  5. 4
  6. Next