diff options
author | Arthur Zamarin <arthurzam@gentoo.org> | 2023-01-15 23:02:52 +0200 |
---|---|---|
committer | Arthur Zamarin <arthurzam@gentoo.org> | 2023-01-16 22:00:20 +0200 |
commit | 75664ae7e124d21b43245e6f6fcfbcd8a588950f (patch) | |
tree | 449cbe3a9c6ddedb7d5a937b9cd243824d4750a0 /testdata | |
parent | ProfilesCheck: check for unknown USE & IUSE_IMPLICIT in make.defaults (diff) | |
download | pkgcheck-75664ae7e124d21b43245e6f6fcfbcd8a588950f.tar.gz pkgcheck-75664ae7e124d21b43245e6f6fcfbcd8a588950f.tar.bz2 pkgcheck-75664ae7e124d21b43245e6f6fcfbcd8a588950f.zip |
ProfilesCheck: check for unknown USE_EXPAND_* in make.defaults
Related: https://github.com/pkgcore/pkgcheck/issues/524
Signed-off-by: Arthur Zamarin <arthurzam@gentoo.org>
Diffstat (limited to 'testdata')
4 files changed, 37 insertions, 0 deletions
diff --git a/testdata/data/repos/profiledir/ProfilesCheck/UnknownProfileUseExpand/expected.json b/testdata/data/repos/profiledir/ProfilesCheck/UnknownProfileUseExpand/expected.json new file mode 100644 index 00000000..5817a2e1 --- /dev/null +++ b/testdata/data/repos/profiledir/ProfilesCheck/UnknownProfileUseExpand/expected.json @@ -0,0 +1,2 @@ +{"__class__": "UnknownProfileUseExpand", "path": "unknown_use/make.defaults", "var": "USE_EXPAND", "groups": ["PYTHON_SINGLE_TARGET"]} +{"__class__": "UnknownProfileUseExpand", "path": "unknown_use/make.defaults", "var": "USE_EXPAND_UNPREFIXED", "groups": ["LUA_TARGETS"]} diff --git a/testdata/data/repos/profiledir/ProfilesCheck/UnknownProfileUseExpand/fix.patch b/testdata/data/repos/profiledir/ProfilesCheck/UnknownProfileUseExpand/fix.patch new file mode 100644 index 00000000..f3932558 --- /dev/null +++ b/testdata/data/repos/profiledir/ProfilesCheck/UnknownProfileUseExpand/fix.patch @@ -0,0 +1,26 @@ +diff -Naur profiledir/profiles/desc/python_single_target.desc fixed/profiles/desc/python_single_target.desc +new file mode 100644 +index 00000000..dcf7e163 +--- /dev/null ++++ fixed/profiles/desc/python_single_target.desc +@@ -0,0 +1,3 @@ ++python3_10 - Build for Python 3.10 only ++python3_11 - Build for Python 3.11 only ++ +diff -Naur profiledir/profiles/unknown_use/make.defaults fixed/profiles/unknown_use/make.defaults +diff --git a/testdata/repos/profiledir/profiles/unknown_use/make.defaults b/testdata/repos/profiledir/profiles/unknown_use/make.defaults +index 6d789215..2c98efd3 100644 +--- profiledir/profiles/unknown_use/make.defaults ++++ fixed/profiles/unknown_use/make.defaults +@@ -1,9 +1,8 @@ + USE="defaults_use used" + IUSE_IMPLICIT="defaults_iuse_implicit used" + USE_EXPAND_IMPLICIT="ARCH ELIBC" +-USE_EXPAND="PYTHON_TARGETS PYTHON_SINGLE_TARGET" +-USE_EXPAND_UNPREFIXED="ARCH LUA_TARGETS PYTHON_TARGETS" ++USE_EXPAND="PYTHON_TARGETS" ++USE_EXPAND_UNPREFIXED="ARCH PYTHON_TARGETS" + USE_EXPAND_VALUES_ARCH="amd64 x86" +-USE_EXPAND_VALUES_LUA_TARGETS="lua5_1" + USE_EXPAND_VALUES_PYTHON_TARGETS="python3_9 python3_10" + PYTHON_TARGETS="python3_9 python3_10" diff --git a/testdata/repos/profiledir/profiles/desc/python_targets.desc b/testdata/repos/profiledir/profiles/desc/python_targets.desc new file mode 100644 index 00000000..75237297 --- /dev/null +++ b/testdata/repos/profiledir/profiles/desc/python_targets.desc @@ -0,0 +1,2 @@ +python3_10 - Build with Python 3.10 +python3_11 - Build with Python 3.11 diff --git a/testdata/repos/profiledir/profiles/unknown_use/make.defaults b/testdata/repos/profiledir/profiles/unknown_use/make.defaults index 4699667b..9bcb7cb9 100644 --- a/testdata/repos/profiledir/profiles/unknown_use/make.defaults +++ b/testdata/repos/profiledir/profiles/unknown_use/make.defaults @@ -1,2 +1,9 @@ USE="defaults_use used" IUSE_IMPLICIT="defaults_iuse_implicit used" +USE_EXPAND_IMPLICIT="ARCH ELIBC" +USE_EXPAND="PYTHON_TARGETS PYTHON_SINGLE_TARGET" +USE_EXPAND_UNPREFIXED="ARCH LUA_TARGETS PYTHON_TARGETS" +USE_EXPAND_VALUES_ARCH="amd64 x86" +USE_EXPAND_VALUES_LUA_TARGETS="lua5_1" +USE_EXPAND_VALUES_PYTHON_TARGETS="python3_9 python3_10" +PYTHON_TARGETS="python3_9 python3_10" |