name: .NET Core

on:
  push:
    branches: [ master ]
  pull_request:
    branches: [ master ]

jobs:
  build:

    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@v2
    - name: Setup .NET Core 3.1
      uses: actions/setup-dotnet@v1
      with:
        dotnet-version: 3.1.x
    - name: Setup .NET Core 2.1
      uses: actions/setup-dotnet@v1
      with:
        dotnet-version: 2.1.x
    - name: Install dependencies
      run: dotnet restore Src/couchbase-net-linq.sln
    - name: Build
      run: dotnet build --configuration Release --no-restore Src/couchbase-net-linq.sln
    - name: Test
      run: dotnet test --no-restore --verbosity normal Src/Couchbase.Linq.UnitTests/Couchbase.Linq.UnitTests.csproj

name: .NET Core

on:
  push:
    branches: [ master ]
  pull_request:
    branches: [ master ]

jobs:
  build:

    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@v2
    - name: Setup .NET Core 2.1
      uses: actions/setup-dotnet@v1
      with:
        dotnet-version: '2.1.807'
    - name: Setup .NET Core 3.1
      uses: actions/setup-dotnet@v1
      with:
        dotnet-version: '3.1.301'
    - name: Setup side by side .NET SDKs on *nix
      run: |
        rsync -a ${DOTNET_ROOT/3.1.301/2.1.807}/* $DOTNET_ROOT/
    - name: Install dependencies
      run: dotnet restore Src/couchbase-net-linq.sln
    - name: Build
      run: dotnet build --configuration Release --no-restore Src/couchbase-net-linq.sln
    - name: Test
      run: dotnet test --no-restore --verbosity normal Src/Couchbase.Linq.UnitTests/Couchbase.Linq.UnitTests.csproj

Enable SxS .net core versions in CI
Enable SxS .net core versions in CI