Skip to content

cleanup and add as github action #272

cleanup and add as github action

cleanup and add as github action #272

Workflow file for this run

name: CI
on: [ push, pull_request ]
jobs:
check-license:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Check for ZDNS License Header
run: |
export NO_HEADERS_FOUND=$(grep -RiL --include="*.go" "ZDNS Copyright .* Regents of the University of Michigan" ./)
if test -n "$NO_HEADERS_FOUND"; then
echo 'FOUND .go FILES WITHOUT HEADERS.'
echo "$NO_HEADERS_FOUND"
exit 1
else
echo 'All .go files in repo have an appropriate header'
fi
build-and-test:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version: '1.20'
- name: Build
run: |
go version
make
- name: Unit Tests
run: go test -v ./...
- name: Integration Tests
run: |
sudo rm /etc/resolv.conf
sudo ln -sf /run/systemd/resolve/resolv.conf /etc/resolv.conf
python --version
./testing/integration_tests.py
build-and-test-top-1k:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version: '1.20'
- name: Build
run: |
go version
make
- name: Large-Scale Integration Test
run: |
python --version
./testing/large_scale_integration_test.py