summaryrefslogtreecommitdiff
path: root/morphlib/workspace_tests.py
diff options
context:
space:
mode:
authorLars Wirzenius <lars.wirzenius@codethink.co.uk>2013-08-01 11:41:16 +0000
committerLars Wirzenius <lars.wirzenius@codethink.co.uk>2013-08-06 12:12:25 +0000
commit2dcda95c15ca788f47bd49f85618364635088b0d (patch)
tree0e8b6f7a03362c3c551b15c74819b92327bc2a2a /morphlib/workspace_tests.py
parent9dd0065a97e49e6e129cc6a5e656eb0d0e657d86 (diff)
downloadmorph-2dcda95c15ca788f47bd49f85618364635088b0d.tar.gz
Add Workspace.get_default_system_branch_directory_name method
This will be useful later, when we start creating system branch directories.
Diffstat (limited to 'morphlib/workspace_tests.py')
-rw-r--r--morphlib/workspace_tests.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/morphlib/workspace_tests.py b/morphlib/workspace_tests.py
index 7837481a..b9c4957a 100644
--- a/morphlib/workspace_tests.py
+++ b/morphlib/workspace_tests.py
@@ -83,3 +83,11 @@ class WorkspaceTests(unittest.TestCase):
morphlib.workspace.NotInWorkspace,
morphlib.workspace.open, self.tempdir)
+ def test_invents_appropriate_name_for_system_branch_directory(self):
+ self.create_it()
+ ws = morphlib.workspace.open(self.workspace_dir)
+ branch = 'foo/bar'
+ self.assertEqual(
+ ws.get_default_system_branch_directory_name(branch),
+ os.path.join(self.workspace_dir, branch))
+