Skip to content

Commit

Permalink
CI:add fsx test
Browse files Browse the repository at this point in the history
  • Loading branch information
YunhuiChen committed Jun 20, 2024
1 parent 5c442dd commit 0162673
Showing 1 changed file with 52 additions and 2 deletions.
54 changes: 52 additions & 2 deletions .github/workflows/integrationtests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ on:
branches:
- 'main'
- 'release-*'
paths:
- '**.c'
- '**.go'
- 'Makefile'
- '**/integrationtests.yml'
paths-ignore:
- 'docs/**'
- '**.md'
Expand All @@ -13,6 +18,11 @@ on:
branches:
- 'main'
- 'release-*'
paths:
- '**.c'
- '**.go'
- 'Makefile'
- '**/integrationtests.yml'
paths-ignore:
- 'docs/**'
- '**.md'
Expand All @@ -26,9 +36,31 @@ on:
default: false

jobs:
build-matrix:
runs-on: ubuntu-20.04
steps:
- id: set-matrix
run: |
echo "github.event_name is ${{github.event_name}}"
echo "GITHUB_REF_NAME is ${GITHUB_REF_NAME}"
if [[ "${{github.event_name}}" == "schedule" || "${{github.event_name}}" == "workflow_dispatch" ]]; then
echo 'meta_matrix=["sqlite3", "redis", "mysql", "tikv", "tidb", "postgres", "badger", "mariadb", "fdb"]' >> $GITHUB_OUTPUT
elif [[ "${{github.event_name}}" == "pull_request" || "${{github.event_name}}" == "push" ]]; then
echo 'meta_matrix=["redis", "mysql", "tikv"]' >> $GITHUB_OUTPUT
else
echo "event_name is not supported" && exit 1
fi
outputs:
meta_matrix: ${{ steps.set-matrix.outputs.meta_matrix }}

integrationtests:
timeout-minutes: 60
runs-on: ubuntu-20.04
needs: build-matrix
strategy:
fail-fast: false
matrix:
meta: ${{ fromJson(needs.build-matrix.outputs.meta_matrix) }}
steps:
- name: Checkout
uses: actions/checkout@v3
Expand Down Expand Up @@ -80,8 +112,26 @@ jobs:
sudo DURATION=60 make -C fstests fsx
sudo make -C fstests xattrs
sudo make -C fstests flock
- name: make secfs.test
run: |
sudo .github/scripts/apt_install.sh libacl1-dev
git clone https://github.com/billziss-gh/secfs.test.git
make -C secfs.test
- name: Fsx Test
timeout-minutes: 16
run: |
if [[ "${{github.event_name}}" == "schedule" || "${{github.event_name}}" == "workflow_dispatch" ]] ; then
duration=900
else
duration=300
fi
sudo touch /jfs/fsx.out
sudo rm -f /tmp/fsx.out
sudo ln -s /jfs/fsx.out /tmp/fsx.out
sudo secfs.test/tools/bin/fsx -d $duration -p 10000 -F 10000000 /tmp/fsx.out
- name: Fsracer
#https://github.com/gfx/example-github-actions-with-tty
shell: 'script -q -e -c "bash {0}"'
Expand Down

0 comments on commit 0162673

Please sign in to comment.