Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
Signed-off-by: Xuewei Niu <justxuewei@apache.org>
  • Loading branch information
justxuewei committed Oct 28, 2023
1 parent 918f22a commit b03dd37
Showing 1 changed file with 15 additions and 13 deletions.
28 changes: 15 additions & 13 deletions .github/workflows/github-actions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@ name: CI

on:
push:
branches:
- main
- 'release-*'
branches: "*"
# branches:
# - main
# - 'release-*'
pull_request:
branches: "*"

Expand Down Expand Up @@ -65,24 +66,25 @@ jobs:
go get -v -t -d ./...
fi
- name: Format code
run: |
go fmt ./... && git status && [[ -z `git status -s` ]]
# - name: Format code
# run: |
# go fmt ./... && git status && [[ -z `git status -s` ]]

- name: Verify
run: |
make verify
# - name: Verify
# run: |
# make verify

- name: Integration Testing
run: |
if [ "$GITHUB_EVENT_NAME" == "pull_request" ]; then
echo "pull_request"
chmod +x integrate_test.sh \
&& [[ -n "${{github.event.pull_request.head.repo.full_name}}" ]] \
&& [[ -n "${{github.event.pull_request.head.sha}}" ]] \
&& [[ -n "${{github.base_ref}}" ]] \
&& ./integrate_test.sh ${{github.event.pull_request.head.repo.full_name}} ${{github.event.pull_request.head.sha}} ${{github.base_ref}}
elif [ "$GITHUB_EVENT_NAME" == "push" ]; then
chmod +x integrate_test.sh && ./integrate_test.sh $GITHUB_REPOSITORY $GITHUB_SHA $GITHUB_BASE_REF
echo "push"
echo "${{github.event.push.ref}}, ${{github.event.push.repository}}, $GITHUB_REPOSITORY, $GITHUB_SHA, $GITHUB_BASE_REF"
chmod +x integrate_test.sh \
&& ./integrate_test.sh $GITHUB_REPOSITORY $GITHUB_SHA $GITHUB_BASE_REF
else
echo "$GITHUB_EVENT_NAME is an unsupported event type."
exit 1
Expand Down

0 comments on commit b03dd37

Please sign in to comment.