diff --git a/azure-pipelines-templates/run-tests.yml b/azure-pipelines-templates/run-tests.yml index c1a1a4ef8..361c3194a 100644 --- a/azure-pipelines-templates/run-tests.yml +++ b/azure-pipelines-templates/run-tests.yml @@ -44,14 +44,21 @@ jobs: strategy: matrix: # We support these versions of Python. - Python 3.9: - python.version: '3.9' - Python 3.10: - python.version: '3.10' + # Python 3.9: + # python.version: '3.9' + # Python 3.10: + # python.version: '3.10' Python 3.11: python.version: '3.11' + Python 3.13: + python.version: '3.13' - maxParallel: 4 + # # Keep compat + # Python 3.7: + # python.version: pypy3.7 + + maxParallel: 2 + # Looks like too much parallelle creates race condition issues between tests..... :( variables: group: sg-credentials @@ -66,13 +73,13 @@ jobs: - task: UsePythonVersion@0 inputs: versionSpec: '$(python.version)' - addToPath: True # Install all dependencies needed for running the tests. This command is good # for all OSes - script: | + python -m pip install --upgrade pip python -m pip install --upgrade pip setuptools wheel - python -m pip install -r tests/ci_requirements.txt + python -m pip install --upgrade -r tests/ci_requirements.txt displayName: Install tools # The {{}} syntax is meant for the the pre-processor of Azure pipeline. Every statement inside @@ -92,6 +99,7 @@ jobs: # Runs the tests and generates test coverage. The tests results are uploaded to Azure Pipelines in the # Tests tab of the build and each test run will be named after the --test-run-title argument to pytest, # for example 'Windows - 2.7' + ## pytest --durations=0 -v --cov shotgun_api3 --cov-report xml --test-run-title="${{parameters.name}}-$(python.version)" - bash: | cp ./tests/example_config ./tests/config pytest --durations=0 -v --cov shotgun_api3 --cov-report xml --test-run-title="${{parameters.name}}-$(python.version)" diff --git a/azure-pipelines.yml b/azure-pipelines.yml index b9be5ab7e..e20fac629 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -79,12 +79,12 @@ jobs: name: Linux vm_image: 'ubuntu-latest' -- template: azure-pipelines-templates/run-tests.yml - parameters: - name: macOS - vm_image: 'macOS-latest' +# - template: azure-pipelines-templates/run-tests.yml +# parameters: +# name: macOS +# vm_image: 'macOS-latest' -- template: azure-pipelines-templates/run-tests.yml - parameters: - name: Windows - vm_image: 'windows-latest' +# - template: azure-pipelines-templates/run-tests.yml +# parameters: +# name: Windows +# vm_image: 'windows-latest' diff --git a/tests/test_api.py b/tests/test_api.py index d0e8407ea..70ccfb79d 100644 --- a/tests/test_api.py +++ b/tests/test_api.py @@ -35,6 +35,20 @@ from . import base +import logging + +# root = logging.getLogger() +# root.setLevel(logging.DEBUG) + +# handler = logging.StreamHandler(sys.stdout) +# handler.setLevel(logging.DEBUG) +# formatter = logging.Formatter("%(asctime)s - %(name)s - %(levelname)s - %(message)s") +# handler.setFormatter(formatter) +# root.addHandler(handler) + +# logger = logging.getLogger("shotgun_api3") +# logger.setLevel(logging.DEBUG) + class TestShotgunApi(base.LiveTestBase): def setUp(self):