name: $(SourceBranchName)-$(Date:yyyyMMdd).$(rev:r)

trigger: none

pr:
  branches:
    include:
    - main
    - release/*
    - v2
    - v3

variables:
- group: open-api-extension-variable-group
- name: TestRunStatus
  value: ''

stages:
- stage: Build
  displayName: 'PR: Build Stage'

  jobs:
  - job: BuildTest
    displayName: 'PR: Build and Test on'

    strategy:
      matrix:
        linux:
          imageName: 'ubuntu-latest'
        mac:
          imageName: 'macos-latest'
        windows:
          imageName: 'windows-latest'

    pool:
      vmImage: '$(imageName)'

    workspace:
      clean: all

    steps:
    - template: 'template-steps-build-test.yaml'
      parameters:
        configuration: 'Debug'
