diff options
author | ben <ben@2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109> | 2002-05-10 23:14:57 +0000 |
---|---|---|
committer | ben <ben@2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109> | 2002-05-10 23:14:57 +0000 |
commit | 40fd4661d4b2a0fd2b2517408d4c5982474b2105 (patch) | |
tree | 6ab957325a74ddf7c64aebdb7424501ca7fc8a45 /rdiff-backup/testing/selectiontest.py | |
parent | 807241bc4f322edc6f95782291900362484263df (diff) | |
download | rdiff-backup-40fd4661d4b2a0fd2b2517408d4c5982474b2105.tar.gz |
Many changes, see changelog for 0.7.4
git-svn-id: http://svn.savannah.nongnu.org/svn/rdiff-backup/trunk@73 2b77aa54-bcbc-44c9-a7ec-4f6cf2b41109
Diffstat (limited to 'rdiff-backup/testing/selectiontest.py')
-rw-r--r-- | rdiff-backup/testing/selectiontest.py | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/rdiff-backup/testing/selectiontest.py b/rdiff-backup/testing/selectiontest.py index 8b16193..9b306eb 100644 --- a/rdiff-backup/testing/selectiontest.py +++ b/rdiff-backup/testing/selectiontest.py @@ -5,12 +5,12 @@ rbexec("highlevel.py") class MatchingTest(unittest.TestCase): """Test matching of file names against various selection functions""" - def makedsrp(self, path): return DSRPath(Globals.local_connection, path) + def makedsrp(self, path): return DSRPath(1, Globals.local_connection, path) def makeext(self, path): return self.root.new_index(tuple(path.split("/"))) def setUp(self): - self.root = DSRPath(Globals.local_connection, "testfiles/select") - self.Select = Select(self.root, 1) + self.root = DSRPath(1, Globals.local_connection, "testfiles/select") + self.Select = Select(self.root) def testRegexp(self): """Test regular expression selection func""" @@ -177,8 +177,8 @@ testfiles/select/1/1 def testRoot(self): """testRoot - / may be a counterexample to several of these..""" - root = DSRPath(Globals.local_connection, "/") - select = Select(root, 1) + root = DSRPath(1, Globals.local_connection, "/") + select = Select(root) assert select.glob_get_sf("/", 1)(root) == 1 assert select.glob_get_sf("/foo", 1)(root) == 1 @@ -205,8 +205,8 @@ class ParseArgsTest(unittest.TestCase): """Test argument parsing""" def ParseTest(self, tuplelist, indicies): """No error if running select on tuple goes over indicies""" - self.root = DSRPath(Globals.local_connection, "testfiles/select") - self.Select = Select(self.root, 1) + self.root = DSRPath(1, Globals.local_connection, "testfiles/select") + self.Select = Select(self.root) self.Select.ParseArgs(tuplelist) self.Select.set_iter() assert Iter.equal(Iter.map(lambda dsrp: dsrp.index, self.Select), @@ -259,8 +259,8 @@ class ParseArgsTest(unittest.TestCase): def testParseStartingFrom(self): """Test parse, this time starting from inside""" - self.root = DSRPath(Globals.local_connection, "testfiles/select") - self.Select = Select(self.root, 1) + self.root = DSRPath(1, Globals.local_connection, "testfiles/select") + self.Select = Select(self.root) self.Select.ParseArgs([("--include", "testfiles/select/1/1"), ("--exclude", "**")]) self.Select.set_iter(('1', '1')) |