Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
Stevent-fei committed Apr 22, 2024
1 parent 005f904 commit 33231cd
Showing 1 changed file with 36 additions and 24 deletions.
60 changes: 36 additions & 24 deletions .github/workflows/e2e-test-apply.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,26 @@
name: Sealer-Test-Apply

#on:
# push:
# branches: "release*"
# issue_comment:
# types:
# - created
# workflow_dispatch: { }
# pull_request_target:
# types: [ opened, synchronize, reopened ]
# branches: "*"
# paths-ignore:
# - 'docs/**'
# - '*.md'
# - '*.yml'
# - '.github'

on:
push:
branches: "release*"
issue_comment:
types:
- created
workflow_dispatch: { }
pull_request_target:
types: [ opened, synchronize, reopened ]
branches: "*"
workflow_dispatch: {}
pull_request:
branches: "*"
paths-ignore:
- 'docs/**'
Expand All @@ -23,7 +35,7 @@ jobs:
build:
name: test
runs-on: ubuntu-latest
if: ${{ (github.event.issue.pull_request && (github.event.comment.body == '/test all' || github.event.comment.body == '/test apply')) || github.event_name == 'push' || github.event_name == 'pull_request_target' }}
#if: ${{ (github.event.issue.pull_request && (github.event.comment.body == '/test all' || github.event.comment.body == '/test apply')) || github.event_name == 'push' || github.event_name == 'pull_request_target' }}
env:
GO111MODULE: on
steps:
Expand Down Expand Up @@ -95,24 +107,24 @@ jobs:
ACCESSKEYID: ${{ secrets.ACCESSKEYID }}
ACCESSKEYSECRET: ${{ secrets.ACCESSKEYSECRET }}
RegionID: ${{ secrets.RegionID }}
if: ${{ github.event.comment.body == '/test apply' || github.event.comment.body == '/test all' || github.event_name == 'push' || github.event_name == 'pull_request_target' }}
#if: ${{ github.event.comment.body == '/test apply' || github.event.comment.body == '/test all' || github.event_name == 'push' || github.event_name == 'pull_request_target' }}
run: |
# fix bug in kernal 5.12.2+:open /proc/sys/net/netfilter/nf_conntrack_max: permission denied, see: https://github.com/kubernetes-sigs/kind/issues/2240
sudo sysctl net/netfilter/nf_conntrack_max=131072
ginkgo -v -focus="sealer apply" -cover -covermode=atomic -coverpkg=./... -coverprofile=/tmp/coverage.out -trace test
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: /tmp/coverage.out
flags: e2e-tests
name: codecov-umbrella

- name: Set final commit status
uses: myrotvorets/set-commit-status-action@master
if: contains(github.event.comment.body, '/test') && always()
with:
sha: ${{ steps.comment-branch.outputs.head_sha }}
token: ${{ secrets.GITHUB_TOKEN }}
status: ${{ job.status }}
# - name: Upload coverage to Codecov
# uses: codecov/codecov-action@v3
# with:
# token: ${{ secrets.CODECOV_TOKEN }}
# files: /tmp/coverage.out
# flags: e2e-tests
# name: codecov-umbrella
#
# - name: Set final commit status
# uses: myrotvorets/set-commit-status-action@master
# if: contains(github.event.comment.body, '/test') && always()
# with:
# sha: ${{ steps.comment-branch.outputs.head_sha }}
# token: ${{ secrets.GITHUB_TOKEN }}
# status: ${{ job.status }}

0 comments on commit 33231cd

Please sign in to comment.