test / test (push) Canceled after 0s
- test.yml: after go test, `go vet ./...` and `go test -c -o /dev/null .` in test/e2e - compiled and linked, not run. Not `go test -run xxx` as the plan said: TestMain would still run and bring up the stand. The Go cache now keys on test/e2e/go.sum too. - .dockerignore: test (e2e leftovers in test/e2e/.stage - DKIM keys, sasldb2 - no longer reach the builder; the sink image is built from test/e2e/sink as its own context, so it is unaffected). - development.md (test.yml line), CHANGELOG [Unreleased], audit plan lines ticked, roadmap 3/61. Evidence on the test server for this tree: make e2e (no SELFPOST_E2E_VERSION, so the "e2e" default path) exit 0, including image_stamped_with_version and the logrotate-mode build; in test/e2e go vet ./... and go test -c -o /dev/null . clean; docker build of build/Dockerfile with a file under test/e2e/.stage succeeds. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
55 lines
1.4 KiB
YAML
55 lines
1.4 KiB
YAML
name: test
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
|
|
jobs:
|
|
test:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
with:
|
|
# design-first.sh reads each commit's parent and the template history.
|
|
fetch-depth: 0
|
|
|
|
- name: Design first
|
|
env:
|
|
BASE: ${{ github.event.pull_request.base.sha || github.event.before }}
|
|
HEAD: ${{ github.event.pull_request.head.sha || github.sha }}
|
|
run: bash .github/scripts/design-first.sh "$BASE" "$HEAD"
|
|
|
|
- uses: actions/setup-go@v5
|
|
with:
|
|
go-version: "1.26"
|
|
cache: true
|
|
cache-dependency-path: |
|
|
go.sum
|
|
test/e2e/go.sum
|
|
|
|
- name: Format
|
|
run: |
|
|
fmt="$(gofmt -l .)"
|
|
if [ -n "$fmt" ]; then
|
|
echo "$fmt"
|
|
echo "gofmt needed on the files above; run 'gofmt -w .'"
|
|
exit 1
|
|
fi
|
|
|
|
- name: Vet
|
|
run: go vet ./...
|
|
|
|
- name: Test
|
|
run: go test ./...
|
|
|
|
# The e2e module runs only in release.yml, after a release is published;
|
|
# a type error there would first show up then. Compile it here without
|
|
# running it: `go test -run` would still run TestMain, which brings up
|
|
# the whole stand.
|
|
- name: Compile the e2e
|
|
working-directory: test/e2e
|
|
run: |
|
|
go vet ./...
|
|
go test -c -o /dev/null .
|