Skip to content

refactor(registry,index,db): centralize key resolution with lazy regi… #262

refactor(registry,index,db): centralize key resolution with lazy regi…

refactor(registry,index,db): centralize key resolution with lazy regi… #262

Workflow file for this run

name: Tests and Build
on:
workflow_dispatch:
push:
branches: [ "*" ]
tags: [ "v*" ]
pull_request:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
with:
# fetching all tags is required for the Makefile to compute the right version
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: "1.24"
- name: Install Protoc
uses: arduino/setup-protoc@v3
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Configure git for private modules
env:
TOKEN: ${{ secrets.REPOSITORIES_ACCESS_TOKEN }}
USER: ${{ secrets.REPOSITORIES_ACCESS_USER }}
run: git config --global url."https://${USER}:${TOKEN}@github.com".insteadOf "https://github.com"
- name: Share cache with other actions
uses: actions/cache@v3
with:
path: |
~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- name: Generate Protobuf
run: make proto
- name: Ensure all files were well formatted
run: make check-fmt
- name: Build
run: make build
tests:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
with:
# fetching all tags is required for the Makefile to compute the right version
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: "1.24"
- name: Configure git for private modules
env:
TOKEN: ${{ secrets.REPOSITORIES_ACCESS_TOKEN }}
USER: ${{ secrets.REPOSITORIES_ACCESS_USER }}
run: git config --global url."https://${USER}:${TOKEN}@github.com".insteadOf "https://github.com"
- name: Share cache with other actions
uses: actions/cache@v3
with:
path: |
~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- name: Run tests and reliability checks
env:
COVERAGE_FLOOR: "60"
BADGERD_COVERAGE_FLOOR: "35"
run: make ci-test
integration-tests:
name: Integration tests
runs-on: ubuntu-latest
strategy:
matrix:
test:
- "TestEmbed"
- "TestServer"
- "TestServerReplicated/sync"
- "TestServerReplicated/async"
steps:
- name: Checkout
uses: actions/checkout@v3
with:
# fetching all tags is required for the Makefile to compute the right version
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: "1.24"
- name: Configure git for private modules
env:
TOKEN: ${{ secrets.REPOSITORIES_ACCESS_TOKEN }}
USER: ${{ secrets.REPOSITORIES_ACCESS_USER }}
run: git config --global url."https://${USER}:${TOKEN}@github.com".insteadOf "https://github.com"
- name: Share cache with other actions
uses: actions/cache@v3
with:
path: |
~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- name: Run integration tests
run: make ci-integration TEST="${{ matrix.test }}"
replication-smoke:
name: Replication smoke
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: "1.24"
- name: Configure git for private modules
env:
TOKEN: ${{ secrets.REPOSITORIES_ACCESS_TOKEN }}
USER: ${{ secrets.REPOSITORIES_ACCESS_USER }}
run: git config --global url."https://${USER}:${TOKEN}@github.com".insteadOf "https://github.com"
- name: Share cache with other actions
uses: actions/cache@v3
with:
path: |
~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- name: Run replication smoke tests
run: make ci-replication-smoke