@@ -180,17 +180,19 @@ MANIFEST.in: init
180180 $(QUIET )$(ECHO ) " exclude .*.yaml" >> " $@ " ;
181181 $(QUIET )$(ECHO ) " exclude .*.conf" >> " $@ " ;
182182 $(QUIET )$(ECHO ) " exclude package.json" >> " $@ " ;
183+ $(QUIET )$(ECHO ) " exclude tests/*.py" >> " $@ " ;
183184 $(QUIET )$(ECHO ) " global-exclude .git" >> " $@ " ;
184185 $(QUIET )$(ECHO ) " global-exclude codecov_env" >> " $@ " ;
185186 $(QUIET )$(ECHO ) " global-exclude .DS_Store" >> " $@ " ;
186187 $(QUIET )$(ECHO ) " global-exclude .local_pip_cleanup.txt" >> " $@ " ;
187- $(QUIET )$(ECHO ) " prune .gitattributes" >> " $@ " ;
188+ $(QUIET )$(ECHO ) " global-exclude .gitattributes" >> " $@ " ;
188189 $(QUIET )$(ECHO ) " prune test-reports" >> " $@ " ;
189190 $(QUIET )$(ECHO ) " prune .github" >> " $@ " ;
190191 $(QUIET )$(ECHO ) " prune .circleci" >> " $@ " ;
191192 $(QUIET )$(ECHO ) " prune venv" >> " $@ " ;
193+ $(QUIET )$(ECHO ) " prune docs" >> " $@ " ;
192194
193- build : init ./setup.py MANIFEST.in
195+ build : init ./pyproject.toml MANIFEST.in
194196 $(QUIET )$(PYTHON ) -W ignore -m build --installer=pip ./ || $(QUIET )$(PYTHON ) -W ignore -m build --sdist --wheel --no-isolation ./ || $(QUIET )$(PYTHON ) -W ignore -m build ./ ;
195197 $(QUIET )$(WAIT )
196198 $(QUIET )$(ECHO ) " build DONE."
@@ -203,7 +205,7 @@ branding::
203205 $(QUIET )$(ECHO ) " "
204206
205207init : branding
206- $(QUIET )$(PYTHON ) -m pip install $(PIP_COMMON_FLAGS ) $(PIP_ENV_FLAGS ) " pip>=24.3.1" " setuptools>=75.0 " " wheel>=0.44 " " build>=1.1 .1" 2> $(ERROR_LOG_PATH ) || :
208+ $(QUIET )$(PYTHON ) -m pip install $(PIP_COMMON_FLAGS ) $(PIP_ENV_FLAGS ) " pip>=24.3.1" " setuptools>=80.4 " " wheel>=0.45 " " build>=1.2 .1" 2> $(ERROR_LOG_PATH ) || :
207209 $(QUIET )$(PYTHON ) -m pip install $(PIP_COMMON_FLAGS ) $(PIP_ENV_FLAGS ) -r requirements.txt 2> $(ERROR_LOG_PATH ) || :
208210 $(QUIET )$(ECHO ) " $@ : Done."
209211
@@ -218,8 +220,6 @@ uninstall:
218220 $(QUIET )$(ECHO ) " $@ : Done."
219221
220222legacy-purge : clean uninstall
221- $(QUIET )$(PYTHON ) -W ignore ./setup.py uninstall 2> $(ERROR_LOG_PATH ) || :
222- $(QUIET )$(PYTHON ) -W ignore ./setup.py clean 2> $(ERROR_LOG_PATH ) || :
223223 $(QUIET )$(RMDIR ) ./build/ 2> $(ERROR_LOG_PATH ) || :
224224 $(QUIET )$(RMDIR ) ./dist/ 2> $(ERROR_LOG_PATH ) || :
225225 $(QUIET )$(RMDIR ) ./.eggs/ 2> $(ERROR_LOG_PATH ) || :
@@ -292,7 +292,7 @@ test-mat-doctests: test-reports MANIFEST.in ## Run doctests MAT category (doctes
292292 $(ECHO ) " Try 'make test-mat-doctests' instead." ; \
293293 else \
294294 $(COVERAGE ) run -p --source=multicast -m tests.run_selective --group mat --category doctests || DO_FAIL=" exit 2" ; \
295- $(QUIET )$( WAIT ) ; \
295+ $(WAIT ) ; \
296296 $(COVERAGE ) combine --keep --data-file=coverage_doctests ./.coverage.* 2> $(ERROR_LOG_PATH ) || : ; \
297297 $(COVERAGE ) report -m --include=multicast/* --data-file=coverage_doctests 2> $(ERROR_LOG_PATH ) || : ; \
298298 $(COVERAGE ) xml -o test-reports/coverage_doctests.xml --include=multicast/* --data-file=coverage_doctests 2> $(ERROR_LOG_PATH ) || : ; \
@@ -304,7 +304,11 @@ test-mat-%: MANIFEST.in ## Run specific MAT category (basic|doctests|say|hear|us
304304 $(QUIET ) if [ -n " $$ TESTS_USE_PYTEST" ]; then \
305305 $(PYTEST ) $(COVERAGE_ARGS ) -m " mat and $* " tests/ || DO_FAIL=" exit 2" ; \
306306 else \
307- $(COVERAGE ) run -p --source=multicast -m tests.run_selective --group mat --category $* ; \
307+ $(COVERAGE ) run -p --source=multicast -m tests.run_selective --group mat --category $* || DO_FAIL=" exit 2" ; \
308+ $(WAIT ) ; \
309+ $(COVERAGE ) combine --keep --data-file=coverage_$* ./.coverage.* 2> $(ERROR_LOG_PATH ) || : ; \
310+ $(COVERAGE ) report -m --include=multicast/* --data-file=coverage_$* 2> $(ERROR_LOG_PATH ) || : ; \
311+ $(COVERAGE ) xml -o test-reports/coverage_$* .xml --include=multicast/* --data-file=coverage_$* 2> $(ERROR_LOG_PATH ) || : ; \
308312 fi
309313 $(QUIET )$(WAIT ) ;
310314 $(QUIET )$(DO_FAIL ) ;
@@ -313,7 +317,11 @@ test-extra: ## Run all extra tests
313317 $(QUIET ) if [ -n " $$ TESTS_USE_PYTEST" ]; then \
314318 $(PYTEST ) $(COVERAGE_ARGS ) -m " extra" tests/ || DO_FAIL=" exit 2" ; \
315319 else \
316- $(COVERAGE ) run -p --source=multicast -m tests.run_selective --group extra; \
320+ $(COVERAGE ) run -p --source=multicast -m tests.run_selective --group extra ; \
321+ $(WAIT ) ; \
322+ $(COVERAGE ) combine --keep --data-file=coverage_extra ./.coverage.* 2> $(ERROR_LOG_PATH ) || : ; \
323+ $(COVERAGE ) report -m --include=multicast/* --data-file=coverage_extra 2> $(ERROR_LOG_PATH ) || : ; \
324+ $(COVERAGE ) xml -o test-reports/coverage_extra.xml --include=multicast/* --data-file=coverage_extra 2> $(ERROR_LOG_PATH ) || : ; \
317325 fi
318326 $(QUIET )$(WAIT ) ;
319327 $(QUIET )$(DO_FAIL ) ;
@@ -322,7 +330,11 @@ test-extra-%: ## Run specific extra test category
322330 $(QUIET ) if [ -n " $$ TESTS_USE_PYTEST" ]; then \
323331 $(PYTEST ) tests/ --verbose $(COVERAGE_ARGS ) -m " extra and $* " || DO_FAIL=" exit 2" ; \
324332 else \
325- $(COVERAGE ) run -p --source=multicast -m tests.run_selective --group extra --category $* ; \
333+ $(COVERAGE ) run -p --source=multicast -m tests.run_selective --group extra --category $* || DO_FAIL=" exit 2" ; \
334+ $(WAIT ) ; \
335+ $(COVERAGE ) combine --keep --data-file=coverage_$* ./.coverage.* 2> $(ERROR_LOG_PATH ) || : ; \
336+ $(COVERAGE ) report -m --include=multicast/* --data-file=coverage_$* 2> $(ERROR_LOG_PATH ) || : ; \
337+ $(COVERAGE ) xml -o test-reports/coverage_$* .xml --include=multicast/* --data-file=coverage_$* 2> $(ERROR_LOG_PATH ) || : ; \
326338 fi
327339 $(QUIET )$(WAIT ) ;
328340 $(QUIET )$(DO_FAIL ) ;
@@ -331,7 +343,11 @@ test-fuzzing: ## Run all fuzzing tests
331343 $(QUIET ) if [ -n " $$ TESTS_USE_PYTEST" ]; then \
332344 $(PYTEST ) tests/ --verbose $(COVERAGE_ARGS ) -m " fuzzing" || DO_FAIL=" exit 2" ; \
333345 else \
334- $(COVERAGE ) run -p --source=multicast -m tests.run_selective --group fuzzing; \
346+ $(COVERAGE ) run -p --source=multicast -m tests.run_selective --group fuzzing || DO_FAIL=" exit 2" ; \
347+ $(WAIT ) ; \
348+ $(COVERAGE ) combine --keep --data-file=coverage_fuzzing ./.coverage.* 2> $(ERROR_LOG_PATH ) || : ; \
349+ $(COVERAGE ) report -m --include=multicast/* --data-file=coverage_fuzzing 2> $(ERROR_LOG_PATH ) || : ; \
350+ $(COVERAGE ) xml -o test-reports/coverage_fuzzing.xml --include=multicast/* --data-file=coverage_fuzzing 2> $(ERROR_LOG_PATH ) || : ; \
335351 fi
336352 $(QUIET )$(WAIT ) ;
337353 $(QUIET )$(DO_FAIL ) ;
@@ -340,7 +356,11 @@ test-perf: ## Run all performance tests
340356 $(QUIET ) if [ -n " $$ TESTS_USE_PYTEST" ]; then \
341357 $(PYTEST ) tests/ --verbose $(COVERAGE_ARGS ) -m " performance" ; \
342358 else \
343- $(COVERAGE ) run -p --source=multicast -m tests.run_selective --group performance; \
359+ $(COVERAGE ) run -p --source=multicast -m tests.run_selective --group performance || DO_FAIL=" exit 2" ; \
360+ $(WAIT ) ; \
361+ $(COVERAGE ) combine --keep --data-file=coverage_performance ./.coverage.* 2> $(ERROR_LOG_PATH ) || : ; \
362+ $(COVERAGE ) report -m --include=multicast/* --data-file=coverage_performance 2> $(ERROR_LOG_PATH ) || : ; \
363+ $(COVERAGE ) xml -o test-reports/coverage_performance.xml --include=multicast/* --data-file=coverage_performance 2> $(ERROR_LOG_PATH ) || : ; \
344364 fi
345365 $(QUIET )$(WAIT ) ;
346366 $(QUIET )$(DO_FAIL ) ;
@@ -412,7 +432,13 @@ cleanup-multicast: cleanup-py-cache-dirs cleanup-py-caches
412432 $(QUIET )$(RM ) multicast/__pycache__/* 2> $(ERROR_LOG_PATH ) || true
413433 $(QUIET )$(RM ) multicast/* /* .pyc 2> $(ERROR_LOG_PATH ) || true
414434
415- cleanup-multicast-eggs : cleanup-dev-backups cleanup-mac-dir-store
435+ cleanup-nested-multicast-eggs : cleanup-dev-backups cleanup-mac-dir-store
436+ $(QUIET )$(RM ) multicast/multicast.egg-info/* 2> $(ERROR_LOG_PATH ) || true
437+ $(QUIET )$(RMDIR ) multicast/multicast.egg-info 2> $(ERROR_LOG_PATH ) || true
438+ $(QUIET )$(RMDIR ) multicast/.eggs 2> $(ERROR_LOG_PATH ) || true
439+ $(QUIET )$(RMDIR ) multicast/.eggs/ 2> $(ERROR_LOG_PATH ) || true
440+
441+ cleanup-multicast-eggs : cleanup-nested-multicast-eggs cleanup-dev-backups cleanup-mac-dir-store
416442 $(QUIET )$(RM ) multicast.egg-info/* 2> $(ERROR_LOG_PATH ) || true
417443 $(QUIET )$(RMDIR ) multicast.egg-info 2> $(ERROR_LOG_PATH ) || true
418444 $(QUIET )$(RMDIR ) .eggs 2> $(ERROR_LOG_PATH ) || true
0 commit comments