Repository navigation
94 lines (78 loc) · 2.56 KB
/
Copy pathconformance.yaml
File metadata and controls
94 lines (78 loc) · 2.56 KB
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
name: Conformance
# The port workflows run only when their own files or dependencies change, but
# their fixture tests compare against values generated from River's Go code.
# This job closes that gap: when Go code, SQL queries the generator reads, or
# the generator itself changes, it regenerates the fixtures and runs only the
# port tests that read them. Keep both events' paths in sync.
on:
push:
branches:
- master
paths:
- ".github/workflows/conformance.yaml"
- "Makefile"
- "**.go"
- "**/go.mod"
- "**/go.sum"
- "conformance/**"
- "go.work"
- "riverdriver/**/*.sql"
pull_request:
paths:
- ".github/workflows/conformance.yaml"
- "Makefile"
- "**.go"
- "**/go.mod"
- "**/go.sum"
- "conformance/**"
- "go.work"
- "riverdriver/**/*.sql"
concurrency:
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
group: ${{ github.workflow }}-${{ github.ref }}
permissions:
contents: read
env:
# Keep the cross-run cache small; Cargo still reuses compiled dependencies.
CARGO_INCREMENTAL: "0"
jobs:
port_fixtures:
name: Port fixture tests
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- uses: actions/checkout@v7
with:
persist-credentials: false
- uses: actions/setup-go@v7
with:
go-version-file: go.work
- uses: dtolnay/rust-toolchain@stable
id: rust
- name: Cache Rust dependencies and build artifacts
uses: actions/cache@v6
with:
path: |
~/.cargo/registry/index
~/.cargo/registry/cache
~/.cargo/git/db
rust/target
key: rust-v1-${{ runner.os }}-${{ runner.arch }}-${{ github.job }}-${{ steps.rust.outputs.cachekey }}-${{ hashFiles('rust/**/Cargo.toml', 'rust/Cargo.lock') }}
restore-keys: rust-v1-${{ runner.os }}-${{ runner.arch }}-${{ github.job }}-${{ steps.rust.outputs.cachekey }}-
- uses: ./.github/actions/setup-js
- uses: ./.github/actions/setup-java
with:
java-version: "21"
# Each target generates the fixtures before running its tests.
- name: Rust fixture tests
run: make test/rust/conformance
- name: JavaScript fixture tests
run: make test/js/conformance
- name: Java fixture tests
run: make test/java/conformance
- uses: ruby/setup-ruby@v1
with:
working-directory: ruby
bundler-cache: true
- name: Ruby fixture tests
run: make test/ruby/conformance