forked from osmosis-labs/osmosis
-
Notifications
You must be signed in to change notification settings - Fork 9
46 lines (44 loc) · 1.58 KB
/
mutest-issue-generate.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
name: Generate Mutation Test Errors
on:
schedule:
- cron: "0 13 1,15 * *" # Bi-weekly – 1PM UTC (9AM EST) on the 1st and 15th of every month
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: checkout repo
uses: actions/checkout@v4
- name: 🐿 Setup Golang
uses: actions/setup-go@v5
with:
go-version: "^1.20"
- name: Display go version
run: go version
- name: Run mutation test
continue-on-error: true
run: make test-mutation $MODULES
env:
MODULES: tokenfactory,twap
- name: Execute mutation test format script
id: mutest-formatted
run: |
grep -Ev "PASS|SKIP" mutation_test_result.txt > mutation_test_result_temp.txt && mv mutation_test_result_temp.txt mutation_test_result.txt
- name: Generate code blocks
id: gen-code-blocks
run: |
cat mutation_test_result.txt | sed "s# @@# @@\n\`\`\`go\n#g " | sed "s#FAIL#\`\`\`\nFAIL\n\n\n#g " > go_mutation_test_result.txt
- name: Get today's date
id: date
run: |
echo "name=today::$(date "+%Y/%m/%d")" >> $GITHUB_STATE
- name: Read mutation_test_txt file
id: result
uses: juliangruber/read-file-action@v1
with:
path: go_mutation_test_result.txt
- name: Create an mutation test output issue
uses: dacbd/create-issue-action@main
with:
token: ${{ secrets.GITHUB_TOKEN }}
title: Mutation test ${{ steps.date.outputs.today }}
body: ${{ steps.result.outputs.content }}