Target .NET Core 3.1.200 on OS X, Linux and Windows

I’m trying to build the app on all three OSes targetting .NET Core 3.1.200
This is my .travis.yml:

language: csharp
os:
  - linux
  - osx
  - windows
mono: none
dist: xenial
dotnet: 3.1.200
before_install:
  - if [ "$TRAVIS_OS_NAME" = "windows" ]; then choco install dotnetcore-sdk; fi
install:
  - dotnet restore
script:
  - dotnet build
  - dotnet test Linalg.Test/Linalg.Test.csproj

The build goes well for OS X and Linux, but fails for Windows. As I found in some topics, I need the before_install in order to install .NET Core 3.1 on Windows. But it fails since the line dotnet: 3.1.200. How to fix it?

My build link: https://travis-ci.org/github/MunchDev/LinalgLibrary/builds/672436929