summaryrefslogtreecommitdiff
path: root/tests/unit/models_containers_test.py
diff options
context:
space:
mode:
authorloicleyendecker <loicleyendecker@users.noreply.github.com>2022-12-02 19:48:04 +0000
committerGitHub <noreply@github.com>2022-12-02 14:48:04 -0500
commit82cf559b5a641f53e9035b44b91f829f3b4cca80 (patch)
tree5d46660cad787972f9f88e7321264d1af9fcb0dd /tests/unit/models_containers_test.py
parent8590eaad3c4b1460606763332ab84b70033ad6a1 (diff)
downloaddocker-py-82cf559b5a641f53e9035b44b91f829f3b4cca80.tar.gz
volume: do not strip trailing characters from names (#3073)
Only remove `:ro` or `:rw` suffixes in their entirety; do not strip arbitrary `r` / `o` / `w` / `:` characters individually. Signed-off-by: Loïc Leyendecker <loic.leyendecker@gmail.com>
Diffstat (limited to 'tests/unit/models_containers_test.py')
-rw-r--r--tests/unit/models_containers_test.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/unit/models_containers_test.py b/tests/unit/models_containers_test.py
index 101708e..51f0018 100644
--- a/tests/unit/models_containers_test.py
+++ b/tests/unit/models_containers_test.py
@@ -103,7 +103,7 @@ class ContainerCollectionTest(unittest.TestCase):
volumes=[
'/home/user1/:/mnt/vol2',
'/var/www:/mnt/vol1:ro',
- 'volumename:/mnt/vol3',
+ 'volumename:/mnt/vol3r',
'/volumewithnohostpath',
'/anothervolumewithnohostpath:ro',
'C:\\windows\\path:D:\\hello\\world:rw'
@@ -123,7 +123,7 @@ class ContainerCollectionTest(unittest.TestCase):
'Binds': [
'/home/user1/:/mnt/vol2',
'/var/www:/mnt/vol1:ro',
- 'volumename:/mnt/vol3',
+ 'volumename:/mnt/vol3r',
'/volumewithnohostpath',
'/anothervolumewithnohostpath:ro',
'C:\\windows\\path:D:\\hello\\world:rw'
@@ -198,7 +198,7 @@ class ContainerCollectionTest(unittest.TestCase):
volumes=[
'/mnt/vol2',
'/mnt/vol1',
- '/mnt/vol3',
+ '/mnt/vol3r',
'/volumewithnohostpath',
'/anothervolumewithnohostpath',
'D:\\hello\\world'