jobs:
-
    job: 'Python2'
    pool:
        vmImage: 'ubuntu-16.04'

    steps:
    -
        script: |
            set -e
            CONDA_ENVIRONMENT=.test-conda-env-py2.yml
            curl -L -O -k https://gitlab.tiker.net/inducer/ci-support/raw/master/build-and-test-py-project-within-miniconda.sh
            . ./build-and-test-py-project-within-miniconda.sh

        displayName: 'Pytest Conda'

-
    job: 'Python3'
    pool:
        vmImage: 'ubuntu-16.04'

    steps:
    -
        script: |
            set -e
            CONDA_ENVIRONMENT=.test-conda-env-py3.yml
            curl -L -O -k https://gitlab.tiker.net/inducer/ci-support/raw/master/build-and-test-py-project-within-miniconda.sh
            . ./build-and-test-py-project-within-miniconda.sh

        displayName: 'Pytest Conda'

    -
        task: PublishTestResults@2
        inputs:
            testResultsFormat: 'JUnit'
            testResultsFiles: 'test/pytest.xml'

-
    job: 'Flake8'
    pool:
        vmImage: 'ubuntu-16.04'
    strategy:
        matrix:
            Python36:
                python.version: '3.6'

    steps:
    -
        task: UsePythonVersion@0
        inputs:
            versionSpec: '$(python.version)'

    -
        script: |
            set -e
            curl -L -O -k https://gitlab.tiker.net/inducer/ci-support/raw/master/prepare-and-run-flake8.sh
            . ./prepare-and-run-flake8.sh pyopencl test

        displayName: 'Flake8'
