Skip to content

Merge pull request #178 from poteto-go/20250103/ch-mod #65

Merge pull request #178 from poteto-go/20250103/ch-mod

Merge pull request #178 from poteto-go/20250103/ch-mod #65

Workflow file for this run

name: Test-1_23
on:
push:
paths:
- "**.go"
- "**.md"
- "**.yaml"
jobs:
test:
runs-on: ubuntu-latest
defaults:
run:
working-directory: .
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Use golang
uses: actions/setup-go@v5
with:
go-version: "1.23.x"
# noinlineによるテスト実行
# https://github.com/poteto-go/poteto/issues/169
- name: Test
run: go test ./... -coverprofile cover.out.tmp -bench . -benchtime 100000x -gcflags=all=-l
- name: remove not template path
run: cat cover.out.tmp | grep -v "github.com/poteto-go/poteto/cmd/template" > cover2.out.tmp
- name: remove not constant path
run: cat cover2.out.tmp | grep -v "github.com/poteto-go/poteto/constant" > cover3.out.tmp
- name: remove example path
run: cat cover3.out.tmp | grep -v "github.com/poteto-go/poteto/constant" > coverage.txt
- name: upload coverage
uses: codecov/codecov-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }}