summaryrefslogtreecommitdiff
path: root/README
diff options
context:
space:
mode:
authorRobert Collins <robertc@robertcollins.net>2011-06-23 17:54:36 +1200
committerRobert Collins <robertc@robertcollins.net>2011-06-23 17:54:36 +1200
commit6b5695a1e5b6969ba16ad382256005c211e281c7 (patch)
treebeda0a73609a73e6b73b215452b4d4976cb8fd86 /README
parent5ef29b108b18a2814944936b3e2862bb53f1b3c2 (diff)
downloadfixtures-6b5695a1e5b6969ba16ad382256005c211e281c7.tar.gz
New fixture ``PackagePathEntry`` which patches the path of an existing
package, allowing importing part of it from aonther directory. (Robert Collins)
Diffstat (limited to 'README')
-rw-r--r--README9
1 files changed, 9 insertions, 0 deletions
diff --git a/README b/README
index 00b7327..84680d9 100644
--- a/README
+++ b/README
@@ -283,6 +283,15 @@ Control the value of a named python attribute.
... pass
>>> fixture = fixtures.MonkeyPatch('__builtin__.open', fake_open)
+PackagePathEntry
+++++++++++++++++
+
+Adds a single directory to the path for an existing python package. This adds
+to the package.__path__ list. If the directory is already in the path, nothing
+happens, if it isn't then it is added on setUp and removed on cleanUp.
+
+ >>> fixture = fixtures.PackagePathEntry('package/name', '/foo/bar')
+
PopenFixture
++++++++++++