aboutsummaryrefslogtreecommitdiff
path: root/unittests
diff options
context:
space:
mode:
authorDaniele Nicolodi <daniele@grinta.net>2023-03-26 10:51:28 +0200
committerJussi Pakkanen <jpakkane@gmail.com>2023-04-14 21:37:52 +0300
commit1bc3d91112c046006da26d1a5c77af4854c6899b (patch)
treead1b5bf04825703cc338f1eba77249aa0770b65e /unittests
parent1c00cb2550517917a655fc6eb6471fc575a32ace (diff)
downloadmeson-1bc3d91112c046006da26d1a5c77af4854c6899b.zip
meson-1bc3d91112c046006da26d1a5c77af4854c6899b.tar.gz
meson-1bc3d91112c046006da26d1a5c77af4854c6899b.tar.bz2
minstall: Fix install_subdir() excludes with path separators on Win
The paths in meson.build use / as path separator, however, the paths constructed during the directory structure walk use native path separators, thus the path never compare equal to the excluded ones. Normalize the exclusion paths before the comparison.
Diffstat (limited to 'unittests')
-rw-r--r--unittests/allplatformstests.py11
1 files changed, 6 insertions, 5 deletions
diff --git a/unittests/allplatformstests.py b/unittests/allplatformstests.py
index a8ec787..493cb9c 100644
--- a/unittests/allplatformstests.py
+++ b/unittests/allplatformstests.py
@@ -441,14 +441,15 @@ class AllPlatformTests(BasePlatformTests):
self.init(testdir)
intro = self.introspect('--installed')
expected = {
+ 'nested_elided/sub': 'share',
+ 'new_directory': 'share/new_directory',
+ 'sub/sub1': 'share/sub1',
+ 'sub1': 'share/sub1',
'sub2': 'share/sub2',
+ 'sub3': '/usr/share/sub3',
+ 'sub_elided': 'share',
'subdir/sub1': 'share/sub1',
'subdir/sub_elided': 'share',
- 'sub1': 'share/sub1',
- 'sub/sub1': 'share/sub1',
- 'sub_elided': 'share',
- 'nested_elided/sub': 'share',
- 'new_directory': 'share/new_directory',
}
self.assertEqual(len(intro), len(expected))