diff options
author | Richard Maw <richard.maw@codethink.co.uk> | 2013-09-19 09:48:06 +0000 |
---|---|---|
committer | Richard Maw <richard.maw@codethink.co.uk> | 2013-09-24 10:26:03 +0000 |
commit | f58e5f85d135d00f92116a97bb8bce82d46f0d36 (patch) | |
tree | e38502022e3ac8fe2aa349b55dbe9d0c9cea37a5 /morphlib/morphset_tests.py | |
parent | 63dccb712d7d741d5a138f7be0647e9befc80094 (diff) | |
download | morph-f58e5f85d135d00f92116a97bb8bce82d46f0d36.tar.gz |
MorphSet: Factor traversal logic out of change_ref
Tweaking all the morphology specs in a MorphologySet is a common
operation.
- Edit does it to rewrite refs
- petrify does it to fix refs to their state at the current point in time
- unpetrify does this to reverse the petrify operation
- branch-from-image works similarly to petrify
After the refs inside morphologies are tweaked, any morphologies in
the MorphSet that are referred to by the changed ref are also updated.
This was previously an operation of change_ref, but it will be useful
for the other use cases.
Changes other than refs are not handled, since there are currently no
use cases for it.
Diffstat (limited to 'morphlib/morphset_tests.py')
-rw-r--r-- | morphlib/morphset_tests.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/morphlib/morphset_tests.py b/morphlib/morphset_tests.py index 65fe2058..69a7057f 100644 --- a/morphlib/morphset_tests.py +++ b/morphlib/morphset_tests.py @@ -145,6 +145,9 @@ class MorphologySetTests(unittest.TestCase): }, ] }) + other_stratum.repo_url = 'test:morphs' + other_stratum.ref = 'master' + other_stratum.filename = 'other-stratum.morph' self.morphs.add_morphology(self.system) self.morphs.add_morphology(self.stratum) |