2 # This file and its contents are supplied under the terms of the
3 # Common Development and Distribution License ("CDDL"), version 1.0.
4 # You may only use this file in accordance with the terms of version
7 # A full copy of the text of the CDDL should have accompanied this
8 # source. A copy of the CDDL is also available via the Internet at
9 # http://www.illumos.org/license/CDDL.
13 # Copyright 2022 Marcel Telka
16 %patch% 02-test-TOX_WORK_DIR.patch
19 # This component is required by following bootstrapped components so it must be
21 # - Userland testing framework (see setup.py.mk)
22 PYTHON_TEST_BOOTSTRAP = yes
24 # Revert back unneeded PYV normalizations ...
25 COMPONENT_TEST_TRANSFORMS += "-e 's/py\$$(PYV)]/py$(shell echo $(PYTHON_VERSION) | tr -d .)]/'"
26 # ... and re-sort list of pytest unit tests after the revert
27 COMPONENT_TEST_TRANSFORMS += \
29 $(GSED) -u -e '/^=\{1,\} test session starts /q' ; \
30 $(GSED) -u -e '/^$$/q' ; \
31 $(GSED) -u -e '/^$$/Q' | $(SORT) | $(NAWK) '{print}END{if(NR>0)printf(\"\\\\n\")}' ; \
33 ) | $(COMPONENT_TEST_TRANSFORMER) -e ''"