39 lines
1.0 KiB
YAML
39 lines
1.0 KiB
YAML
name: Test
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
concurrency:
|
|
group: test-${{ github.ref }}
|
|
cancel-in-progress: true
|
|
|
|
jobs:
|
|
bun-test:
|
|
name: bun test
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: oven-sh/setup-bun@v2
|
|
with:
|
|
# Pinned (not `latest`) so the action skips the GitHub API tag
|
|
# lookup that gets rate-limited on shared-IP runners. Reproducible
|
|
# CI builds as a side benefit. Bump deliberately when needed.
|
|
bun-version: 1.3.14
|
|
|
|
- name: Validate internal registry install wiring
|
|
run: bash .gitea/scripts/tests/test_internal_registry_install.sh
|
|
|
|
- name: Install dependencies from the unauthenticated internal registry
|
|
run: |
|
|
set -euo pipefail
|
|
cache_dir="$(mktemp -d)"
|
|
trap 'rm -rf "$cache_dir"' EXIT
|
|
BUN_INSTALL_CACHE_DIR="$cache_dir" bun install --frozen-lockfile
|
|
- name: Run tests
|
|
run: bun test
|