name: CI-Windows

on: [push]

jobs:
  build-n-run-tests:

    runs-on: windows-2019
    
    steps:
    - uses: actions/checkout@master
    - name: Build Everything
      run: |
        dotnet build
    - name: Download OSMesa Binary
      run: |
        curl -L http://github.com/pal1000/mesa-dist-win/releases/download/19.1.6/mesa3d-19.1.6-release-mingw.7z -o mesa.7z
        7z x mesa.7z
        mkdir .\Tests\bin\Debug\netcoreapp3.0\mesa
        mv .\x64\opengl32.dll .\Tests\bin\Debug\netcoreapp3.0\mesa\opengl32.dll
        ls .\Tests\bin\Debug\netcoreapp3.0
    - name: Run Tests
      run: |
        cd .\Tests\bin\Debug\netcoreapp3.0
        ls .
        .\Tests.exe
    - name: Upload Test Artifact
      uses: actions/upload-artifact@master
      with:
        name: Test Result Artifact
        path: Tests\bin\Debug\netcoreapp3.0\TestResults

        
        
        

name: CI-Windows

on: [push]

jobs:
  build-n-run-tests:

    runs-on: windows-2019
    
    steps:
    - uses: actions/checkout@master
    - name: Build Everything
      run: |
        dotnet build
    - name: Download OSMesa Binary
      run: |
        curl -L http://github.com/pal1000/mesa-dist-win/releases/download/19.1.6/mesa3d-19.1.6-release-mingw.7z -o mesa.7z
        7z x mesa.7z
        mkdir .\Tests\bin\Debug\netcoreapp3.0\mesa
        mv .\x64\opengl32.dll .\Tests\bin\Debug\netcoreapp3.0\mesa\opengl32.dll
        ls .\Tests\bin\Debug\netcoreapp3.0
    - name: Run Tests
      run: |
        cd .\Tests\bin\Debug\netcoreapp3.0
        ls .
        .\Tests.exe
    - name: Upload Test Artifact
      if: always()
      uses: actions/upload-artifact@master
      with:
        name: Test Result Artifact
        path: Tests\bin\Debug\netcoreapp3.0\TestResults

        
        
        

Test artifact will be created even if the build fails.
Test artifact will be created even if the build fails.
