forked from DataObjects-NET/dataobjects-net
-
Notifications
You must be signed in to change notification settings - Fork 3
34 lines (33 loc) · 1.1 KB
/
test-postgres.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
name: Tests with PostgreSQL
on:
pull_request:
branches: [ master-servicetitan ]
env:
DOTNET_CLI_TELEMETRY_OPTOUT: "true"
DO_CONFIG_FILE: "/tmp/do-test.cfg"
DO_STORAGE: "pgsql160"
DO_TargetFrameworks: net8.0
jobs:
test-with-postgresql:
name: SQL tests
runs-on: ubuntu-latest
timeout-minutes: 120
steps:
- uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with: { dotnet-version: 8 }
- uses: ikalnytskyi/action-setup-postgres@v6
- name: Init Test DB
run: |
createuser dotest
createdb --owner dotest dotest
psql -c "ALTER USER dotest WITH PASSWORD 'dotest' SUPERUSER"
env:
PGSERVICE: ${{ steps.postgres.outputs.service-name }}
- name: Create DO Tests Config file
run: echo default=postgresql://dotest:dotest@localhost/dotest >$DO_CONFIG_FILE
- name: Build
run: dotnet build -v q Orm.sln
- name: Tests
run: dotnet test --no-build -v n Orm/Xtensive.Orm.Tests.Sql/Xtensive.Orm.Tests.Sql.csproj --filter 'TestCategory!=Mute'