mirror of
				https://github.com/ets-labs/python-dependency-injector.git
				synced 2025-11-01 00:17:55 +03:00 
			
		
		
		
	
		
			
				
	
	
		
			68 lines
		
	
	
		
			1.7 KiB
		
	
	
	
		
			YAML
		
	
	
	
	
	
			
		
		
	
	
			68 lines
		
	
	
		
			1.7 KiB
		
	
	
	
		
			YAML
		
	
	
	
	
	
| name: Tests and linters
 | |
| 
 | |
| on: [push, pull_request, workflow_dispatch]
 | |
| 
 | |
| jobs:
 | |
| 
 | |
|   test-on-different-versions:
 | |
|     name: Run tests
 | |
|     runs-on: ubuntu-latest
 | |
|     strategy:
 | |
|       matrix:
 | |
|         python-version: ["3.8", "3.9", "3.10", "3.11", "3.12", "3.13"]
 | |
|     steps:
 | |
|       - uses: actions/checkout@v3
 | |
|       - uses: actions/setup-python@v4
 | |
|         with:
 | |
|           python-version: ${{ matrix.python-version }}
 | |
|       - run: pip install tox
 | |
|       - run: tox
 | |
|         env:
 | |
|           DEPENDENCY_INJECTOR_LIMITED_API: 1
 | |
|           TOXENV: ${{ matrix.python-version }}
 | |
| 
 | |
|   test-different-pydantic-versions:
 | |
|     name: Run tests with different pydantic versions
 | |
|     runs-on: ubuntu-latest
 | |
|     steps:
 | |
|       - uses: actions/checkout@v3
 | |
|       - uses: actions/setup-python@v4
 | |
|         with:
 | |
|           python-version: "3.12"
 | |
|       - run: pip install tox
 | |
|       - run: tox -e pydantic-v1,pydantic-v2
 | |
| 
 | |
|   test-coverage:
 | |
|     name: Run tests with coverage
 | |
|     runs-on: ubuntu-latest
 | |
|     env:
 | |
|       DEPENDENCY_INJECTOR_DEBUG_MODE: 1
 | |
|       PIP_VERBOSE: 1
 | |
|       COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
 | |
|       GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
 | |
|     steps:
 | |
|       - uses: actions/checkout@v3
 | |
|       - uses: actions/setup-python@v4
 | |
|         with:
 | |
|           python-version: 3.12
 | |
|       - run: pip install tox
 | |
|       - run: tox -vv
 | |
|         env:
 | |
|           TOXENV: coveralls
 | |
| 
 | |
|   linters:
 | |
|     name: Run linters
 | |
|     runs-on: ubuntu-latest
 | |
|     strategy:
 | |
|       matrix:
 | |
|         toxenv: [flake8, pydocstyle, mypy, pylint]
 | |
|     steps:
 | |
|       - uses: actions/checkout@v3
 | |
|       - uses: actions/setup-python@v4
 | |
|         with:
 | |
|           python-version: 3.13
 | |
|       - run: pip install tox
 | |
|       - run: tox
 | |
|         env:
 | |
|           TOXENV: ${{ matrix.toxenv }}
 |