changeset 491:152a15046b41

tests: Normalize test paths using the correct method.
author Ludovic Chabant <ludovic@chabant.com>
date Wed, 22 Jul 2015 22:21:42 -0700
parents 4a9047850657
children d90ccdf18156
files tests/basefs.py
diffstat 1 files changed, 2 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/tests/basefs.py	Wed Jul 22 22:20:35 2015 -0700
+++ b/tests/basefs.py	Wed Jul 22 22:21:42 2015 -0700
@@ -33,16 +33,12 @@
         return PieCrust(root_dir, cache=cache, debug=True)
 
     def withDir(self, path):
-        path = path.replace('\\', '/')
-        path = path.lstrip('/')
-        path = '/%s/%s' % (self._root, path)
+        path = self.path(path)
         self._createDir(path)
         return self
 
     def withFile(self, path, contents):
-        path = path.replace('\\', '/')
-        path = path.lstrip('/')
-        path = '/%s/%s' % (self._root, path)
+        path = self.path(path)
         self._createFile(path, contents)
         return self