Skip to content

build(deps): bump github.com/matryer/moq from 0.4.0 to 0.5.1 in /internal/tools #2003

build(deps): bump github.com/matryer/moq from 0.4.0 to 0.5.1 in /internal/tools

build(deps): bump github.com/matryer/moq from 0.4.0 to 0.5.1 in /internal/tools #2003

Workflow file for this run

name: ci
on:
push:
branches:
- main
pull_request:
env:
# Path to where test results will be saved.
TEST_RESULTS: /tmp/test-results
# Default minimum version of Go to support.
DEFAULT_GO_VERSION: "~1.22.7"
jobs:
lint:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: ${{ env.DEFAULT_GO_VERSION }}
check-latest: true
- name: Checkout Repo
uses: actions/checkout@v4
- name: Module cache
uses: actions/cache@v4
env:
cache-name: go-mod-cache
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-${{ env.cache-name }}-${{ hashFiles('**/go.sum') }}
- name: Tools cache
id: cache-tools
uses: actions/cache@v4
env:
cache-name: go-tools-cache
with:
path: .tools
key: ${{ runner.os }}-${{ env.cache-name }}-${{ hashFiles('./internal/tools/**') }}
- name: Install tools
if: steps.cache-tools.outputs.cache-hit != 'true'
run: make tools
- name: Add .exe to tools on Windows
if: matrix.os == 'windows-latest'
shell: bash
run: |
for file in ./.tools/*; do
cp "$file" "${file}.exe"
done
- name: Run linters
run: make multimod-verify dependabot-check license-check lint
- name: Build
run: make build
- name: Check clean repository
run: make check-clean-work-tree
test-race:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: ${{ env.DEFAULT_GO_VERSION }}
check-latest: true
- name: Checkout Repo
uses: actions/checkout@v4
- name: Setup Environment
run: |
echo "GOPATH=$(go env GOPATH)" >> $GITHUB_ENV
echo "$(go env GOPATH)/bin" >> $GITHUB_PATH
- name: Module cache
uses: actions/cache@v4
env:
cache-name: go-mod-cache
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-${{ env.cache-name }}-${{ hashFiles('**/go.sum') }}
- name: Run tests with race detector
run: make test-race
test-coverage:
runs-on: ubuntu-latest
steps:
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: ${{ env.DEFAULT_GO_VERSION }}
check-latest: true
- name: Checkout Repo
uses: actions/checkout@v4
- name: Setup Environment
run: |
echo "GOPATH=$(go env GOPATH)" >> $GITHUB_ENV
echo "$(go env GOPATH)/bin" >> $GITHUB_PATH
- name: Module cache
uses: actions/cache@v4
env:
cache-name: go-mod-cache
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-${{ env.cache-name }}-${{ hashFiles('**/go.sum') }}
- name: Run coverage tests
run: |
make test-coverage
mkdir $TEST_RESULTS
cp coverage.out $TEST_RESULTS
cp coverage.txt $TEST_RESULTS
cp coverage.html $TEST_RESULTS
- name: Upload coverage report
uses: codecov/codecov-action@v5.1.1
with:
file: ./coverage.txt
fail_ci_if_error: true
verbose: true
token: ${{ secrets.CODECOV_TOKEN }}
- name: Store coverage test output
uses: actions/upload-artifact@v4
with:
name: opentelemetry-go-test-output
path: ${{ env.TEST_RESULTS }}