mirror of
https://github.com/MacRimi/ProxMenux.git
synced 2026-11-02 10:52:22 +00:00
Name the overlapping mount paths and fix new OCI review translations
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
"""Regression tests for explicit adoption of external OCI resources."""
|
||||
import copy
|
||||
import json
|
||||
from pathlib import Path
|
||||
import sys
|
||||
@@ -216,5 +217,17 @@ class EnvironmentAdoptionTests(unittest.TestCase):
|
||||
reconcile.propose(record, config)
|
||||
|
||||
|
||||
class OverlapMessageTests(unittest.TestCase):
|
||||
def test_the_refusal_names_both_paths(self):
|
||||
from test_modify_review import installation
|
||||
saved, config = installation()
|
||||
candidate = copy.deepcopy(saved)
|
||||
volume = {'type': 'managed-volume', 'source': 'local-lvm', 'size_gb': 1, 'backup': True, 'read_only': False}
|
||||
candidate['deployment']['mounts'] = [dict(volume, container_path='/source'),
|
||||
dict(volume, container_path='/source/archivos')]
|
||||
with self.assertRaisesRegex(ValueError, '/source/archivos - /source$'):
|
||||
reconcile.transaction.preflight(saved, candidate, config)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
unittest.main()
|
||||
|
||||
Reference in New Issue
Block a user