Skip to content

Commit da2c1b9

Browse files
committed
tests: add ci
1 parent be66c74 commit da2c1b9

1 file changed

Lines changed: 46 additions & 0 deletions

File tree

.github/workflows/go-test.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: Go CI
2+
3+
#on:
4+
# push:
5+
# branches:
6+
# - main
7+
# pull_request:
8+
# branches:
9+
# - main
10+
11+
jobs:
12+
test:
13+
name: Test all
14+
runs-on: ubuntu-latest
15+
env:
16+
SKIPPED_TESTS: >-
17+
TestPatcher|TestCases|Test_goParser_ParseNode|TestParser_NodeFieldsConsistency
18+
# TestPatcher:
19+
# absolute path in localsession.json
20+
# TestCases:
21+
# hardcoded obselete json
22+
# Test_goParser_ParseNode:
23+
# test tries to retrieve non-existent node
24+
# TestParser_NodeFieldsConsistency:
25+
# Vars.Content only includes name, not whole body
26+
27+
steps:
28+
- name: Checkout code
29+
uses: actions/checkout@v4
30+
31+
- name: Setup Go
32+
uses: actions/setup-go@v5
33+
with:
34+
go-version: '1.22'
35+
36+
- name: Setup Rust toolchain
37+
uses: dtolnay/rust-toolchain@stable
38+
with:
39+
toolchain: stable
40+
components: rust-analyzer
41+
42+
- name: Install gopls
43+
run: go install golang.org/x/tools/gopls@latest
44+
45+
- name: Run all tests
46+
run: go test ./lang/... -skip '${{ env.SKIPPED_TESTS }}'

0 commit comments

Comments
 (0)