# HG changeset patch # User domruf # Date 2017-04-27 20:29:28 # Node ID 52e689b37700a2d6a9c59c95514c7241d063d4a1 # Parent f89dba9ea7c766aaa2e1a289745664b8da4bfb8d tests: use relative path when adding file to git repo (fixes error with newer git versions) Newer git versions would fail 'git add /path/to/file' with: fatal: /path/to/file: '/path/to/file' is outside repository That caused test_push_unlocks_repository_git to fail. To fix that, use relative instead of absolute path. diff --git a/kallithea/tests/other/manual_test_vcs_operations.py b/kallithea/tests/other/manual_test_vcs_operations.py --- a/kallithea/tests/other/manual_test_vcs_operations.py +++ b/kallithea/tests/other/manual_test_vcs_operations.py @@ -113,9 +113,9 @@ def _add_files_and_push(vcs, DEST, **kwa :param DEST: """ # commit some stuff into this repo - cwd = path = os.path.join(DEST) - #added_file = os.path.join(path, '%ssetupążźć.py' % _RandomNameSequence().next()) - added_file = os.path.join(path, '%ssetup.py' % _RandomNameSequence().next()) + cwd = os.path.join(DEST) + #added_file = '%ssetupążźć.py' % _RandomNameSequence().next() + added_file = '%ssetup.py' % _RandomNameSequence().next() Command(cwd).execute('touch %s' % added_file) Command(cwd).execute('%s add %s' % (vcs, added_file))