-
Notifications
You must be signed in to change notification settings - Fork 123
63 lines (52 loc) · 1.49 KB
/
build-test.yml
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
name: 🔨 Build Test
on:
pull_request:
paths:
- '**.go'
- '**.mod'
workflow_dispatch:
jobs:
build:
name: Test Builds
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macOS-latest]
go-version: [1.21.x]
steps:
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: ${{ matrix.go-version }}
- name: Check out code
uses: actions/checkout@v3
- name: Build
run: go build .
working-directory: cmd/cvemap/
- name: Test
run: go test ./...
working-directory: .
- name: Integration Tests Linux, macOS
if: runner.os == 'Linux' || runner.os == 'macOS'
env:
GH_ACTION: true
run: bash run.sh
working-directory: cmd/integration-test/
- name: Integration Tests Windows
if: runner.os == 'Windows'
env:
GH_ACTION: true
MSYS_NO_PATHCONV: true
run: bash run.sh
working-directory: cmd/integration-test/
- name: Race Condition Tests
if: github.actor != 'dependabot[bot]'
run: go run -race . -id CVE-1999-0027
working-directory: cmd/cvemap/
env:
PDCP_API_KEY: "${{ secrets.PDCP_API_KEY }}"
PDCP_API_SERVER: https://api.projectdiscovery.io
DEBUG: true
# - name: Test Example Code
# run: go run .
# working-directory: examples/