Skip to content

support :execrows for sqlite #12

support :execrows for sqlite

support :execrows for sqlite #12

Workflow file for this run

name: .Net Framework Tests (Legacy)
defaults:
run:
shell: bash
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "*" ]
paths:
- "**"
- "!**.md"
jobs:
# As this can run only on Windows machines, these tests should run only in CI
end2end-tests:
name: End-to-End Tests
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Load .env file
uses: xom9ikk/dotenv@v2.3.0
with:
load-mode: strict
- name: Setup Visual Studio for .NET Framework
uses: microsoft/setup-msbuild@v1
with:
vs-version: 'latest'
- name: Setup NuGet
uses: NuGet/setup-nuget@v2.0.1
- name: Install Chocolatey
shell: powershell
run: |
Set-ExecutionPolicy Bypass -Scope Process -Force
[System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072
iex ((New-Object System.Net.WebClient).DownloadString('https://community.chocolatey.org/install.ps1'))
- uses: ikalnytskyi/action-setup-postgres@v7
with:
username: ${{ env.POSTGRES_USER }}
password: ${{ env.POSTGRES_PASSWORD }}
database: ${{ env.TESTS_DB }}
postgres-version: "16"
id: postgres
- name: Init PostgresSQL Schema
shell: powershell
run: psql -U $Env:POSTGRES_USER -f 'examples/config/postgresql/schema.sql'
env:
PGSERVICE: ${{ steps.postgres.outputs.service-name }}
PGPASSWORD: ${{ env.POSTGRES_PASSWORD }}
- name: Install MySQL and restore test projects in parallel
shell: pwsh
run: |
$mysql_job = Start-Job -ScriptBlock {
choco install mysql --no-progress --version=8.0.31 -y --params "/serviceName:MySQL"
}
$restore_job = Start-Job -ScriptBlock {
Get-ChildItem -Path examples -Recurse -Filter *.csproj |
Where-Object { $_.FullName -like '*Legacy*' } |
ForEach-Object { nuget restore $_.FullName }
nuget restore ./LegacyEndToEndTests/LegacyEndToEndTests.csproj
msbuild.exe ./LegacyEndToEndTests/LegacyEndToEndTests.csproj -p:Configuration=Release -p:FrameworkVersion=v4.7.2
}
Wait-Job -Job $mysql_job, $restore_job
Receive-Job -Job $mysql_job
Receive-Job -Job $restore_job
- name: Init MySQL Schema
shell: powershell
run: |
$env:Path += ";C:\Program Files\MySQL\MySQL Server 8.0\bin"
[Environment]::SetEnvironmentVariable("Path", $env:Path, "Machine")
mysql -u root -e "CREATE DATABASE $Env:TESTS_DB;"
mysql -u root $Env:TESTS_DB --execute="source examples/config/mysql/schema.sql"
- name: Run Tests
shell: powershell
run: |
$path = vswhere -latest -products * -requires Microsoft.VisualStudio.Workload.ManagedDesktop Microsoft.VisualStudio.Workload.Web -requiresAny -property installationPath
$path = join-path $path 'Common7\IDE\CommonExtensions\Microsoft\TestWindow\vstest.console.exe'
& $path ./LegacyEndToEndTests/bin/Release/net472/LegacyEndToEndTests.dll