PTU5KAS/tests
Jan Kiszka 2077900b4e includehandler: Fix repo path detection for local includes
So far, repository paths for local includes were derived from the path
name of the config file containing the include, rather than using the
actual repository root as specified in the documentation. No one
complained so far, some layers simply adjusted their includes to this
inconsistency which was only discovered during refactorings.

Fix this issue by passing also the repository path along with the config
filename down the recursive _internal_include_handler calls. The
top-level repo path now needs to be retrieved before the creation of
IncludeHandler and passed to it then. This has the side effect of
enabling deviating top-level repo paths, a feature that will be used by
the upcoming changes for a .config.yaml file in KAS_WORK_DIR.

As there are existing users of the old behavior out there, fall back to
it if a local include cannot be found under the correct path and warn if
this succeeds. This allows smooth migration of layers to the right
pattern as they update their kas version.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
2021-08-19 10:10:14 +02:00
..
test_build_system tests: Stress the build_system property 2020-11-16 11:53:29 +01:00
test_commands tests: Add tests for new for-all-repos & checkout commands 2020-11-17 17:57:59 +01:00
test_environment_variables Introduce KAS_BUILD_DIR environment variable 2021-03-10 07:53:09 +01:00
test_layers repos: strip dot from layer name 2021-05-05 15:43:58 +02:00
test_patch tests: Check patches can still be applied after switching refspec 2020-06-15 19:53:59 +02:00
test_refspec Enable gerrit/gitlab/github refspecs 2021-07-19 07:57:32 +02:00
conftest.py tests: Extract common changedir fixture 2020-11-13 21:00:35 +01:00
test_build_system.py tests: Stress the build_system property 2020-11-16 11:53:29 +01:00
test_commands.py tests: Add tests for new for-all-repos & checkout commands 2020-11-17 17:57:59 +01:00
test_environment_variables.py Introduce KAS_BUILD_DIR environment variable 2021-03-10 07:53:09 +01:00
test_includehandler.py includehandler: Fix repo path detection for local includes 2021-08-19 10:10:14 +02:00
test_layers.py repos: strip dot from layer name 2021-05-05 15:43:58 +02:00
test_patch.py tests: Extract common changedir fixture 2020-11-13 21:00:35 +01:00
test_refspec.py Enable gerrit/gitlab/github refspecs 2021-07-19 07:57:32 +02:00