diff options
author | David Mulder <dmulder@suse.com> | 2021-03-09 12:30:14 -0700 |
---|---|---|
committer | Karolin Seeger <kseeger@samba.org> | 2021-03-31 10:13:54 +0000 |
commit | 702e0c55989b9e2975eb761c6776d3b866ee512f (patch) | |
tree | f432b05e0073565c9254d294680fa7d75f96678e /python | |
parent | 231342faf2f5f6ab2287967f317cb1a862083a7f (diff) | |
download | samba-702e0c55989b9e2975eb761c6776d3b866ee512f.tar.gz |
samba-gpupdate: Test that sysvol paths download in case-insensitive way
Bug: https://bugzilla.samba.org/show_bug.cgi?id=14665
Signed-off-by: David Mulder <dmulder@suse.com>
Reviewed-by: Björn Baumbach <bb@sernet.de>
(cherry picked from commit 554f2134a9f9638ebd8ac2500e5b6c94b74c27d5)
Diffstat (limited to 'python')
-rw-r--r-- | python/samba/tests/gpo.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/python/samba/tests/gpo.py b/python/samba/tests/gpo.py index a0dce8d96d7..0afc2091b3e 100644 --- a/python/samba/tests/gpo.py +++ b/python/samba/tests/gpo.py @@ -181,6 +181,16 @@ class GPOTests(tests.TestCase): self.assertEqual(result, after, 'check_safe_path() didn\'t' ' correctly convert \\ to /') + def test_check_safe_path_typesafe_name(self): + path = '\\\\toady.suse.de\\SysVol\\toady.suse.de\\Policies\\' \ + '{31B2F340-016D-11D2-945F-00C04FB984F9}\\GPT.INI' + expected_path = 'toady.suse.de/Policies/' \ + '{31B2F340-016D-11D2-945F-00C04FB984F9}/GPT.INI' + + result = check_safe_path(path) + self.assertEqual(result, expected_path, + 'check_safe_path unable to detect variable case sysvol components') + def test_gpt_ext_register(self): this_path = os.path.dirname(os.path.realpath(__file__)) samba_path = os.path.realpath(os.path.join(this_path, '../../../')) |