Skip to content

Commit

Permalink
test: refine test cases (#655)
Browse files Browse the repository at this point in the history
* test: refine test cases

* fix: 3.0-taosbenchmark-*

* fix: add schedule event

* test: merge with develop
  • Loading branch information
sangshuduo committed May 17, 2023
1 parent dbc9ebf commit aa67feb
Show file tree
Hide file tree
Showing 35 changed files with 218 additions and 67 deletions.
5 changes: 5 additions & 0 deletions .github/workflows/2.x-aarch64.yml
Expand Up @@ -92,6 +92,7 @@ jobs:
(steps.changed-files-specific.outputs.any_changed == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
uses: actions/checkout@v2
with:
submodules: recursive
Expand All @@ -104,6 +105,7 @@ jobs:
(steps.changed-files-specific.outputs.any_changed == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
run: |
echo "The uname output was ${{ steps.setup.outputs.uname }}"
sudo timedatectl set-timezone Asia/Shanghai
Expand Down Expand Up @@ -131,6 +133,7 @@ jobs:
(steps.changed-files-specific.outputs.any_changed == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
uses: uraimo/run-on-arch-action@v2
with:
arch: aarch64
Expand All @@ -156,6 +159,7 @@ jobs:
(steps.changed-files-specific.outputs.any_changed == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
uses: uraimo/run-on-arch-action@v2
with:
arch: aarch64
Expand All @@ -182,6 +186,7 @@ jobs:
(steps.changed-files-specific.outputs.any_changed == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
uses: uraimo/run-on-arch-action@v2
with:
arch: aarch64
Expand Down
9 changes: 9 additions & 0 deletions .github/workflows/2.x-archlinux-release.yml
Expand Up @@ -83,6 +83,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
run: |
pacman -Syu --noconfirm > /dev/null
pacman -Sy git --noconfirm > /dev/null
Expand All @@ -92,6 +93,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
uses: actions/checkout@v2
with:
submodules: recursive
Expand All @@ -104,6 +106,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
run: |
echo "disable timezone changing"
#timedatectl set-timezone Asia/Shanghai
Expand All @@ -123,6 +126,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
uses: actions/setup-go@v3
with:
go-version: 1.17
Expand All @@ -132,6 +136,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
uses: actions-rs/toolchain@v1
with:
toolchain: stable
Expand All @@ -141,6 +146,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
id: cache-rust
with:
path: |
Expand All @@ -155,6 +161,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
run: |
pacman -Sy --noconfirm gcc make cmake zlib snappy gcc-libs pkg-config python3 python-pip > /dev/null
gcc --version
Expand All @@ -171,6 +178,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
run: |
pip3 install decorator numpy fabric2 psutil pandas faker toml > /dev/null
pip3 install taospy > /dev/null
Expand All @@ -187,6 +195,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
run: |
if [ -f ~/taosdump-failed.txt ]; then
cat ~/taosdump-failed.txt;
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/2.x-armv7.yml
Expand Up @@ -92,6 +92,7 @@ jobs:
(steps.changed-files-specific.outputs.any_changed == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
uses: actions/checkout@v2
with:
submodules: recursive
Expand All @@ -104,6 +105,7 @@ jobs:
(steps.changed-files-specific.outputs.any_changed == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
run: |
echo "The uname output was ${{ steps.setup.outputs.uname }}"
sudo timedatectl set-timezone Asia/Shanghai
Expand Down Expand Up @@ -131,6 +133,7 @@ jobs:
(steps.changed-files-specific.outputs.any_changed == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
uses: uraimo/run-on-arch-action@v2
with:
arch: armv7
Expand Down
9 changes: 9 additions & 0 deletions .github/workflows/2.x-centos-release.yml
Expand Up @@ -83,6 +83,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
run: |
echo "yum update"
yum update -y > /dev/null
Expand All @@ -99,6 +100,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
uses: actions/checkout@v2
with:
submodules: recursive
Expand All @@ -111,6 +113,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
run: |
echo "disable timezone changing"
#timedatectl set-timezone Asia/Shanghai
Expand All @@ -130,6 +133,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
uses: actions/setup-go@v3
with:
go-version: 1.17
Expand All @@ -139,6 +143,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
uses: actions-rs/toolchain@v1
with:
toolchain: stable
Expand All @@ -148,6 +153,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
id: cache-rust
with:
path: |
Expand All @@ -162,6 +168,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
run: |
yum install -y python3 python3-pip zlib-devel zlib-static xz-devel snappy-devel jansson jansson-devel pkgconfig libatomic libatomic-static libstdc++-static openssl-devel > /dev/null
python3 -m pip install --upgrade pip > /dev/null 2>&1
Expand All @@ -177,6 +184,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
run: |
pip3 install decorator numpy fabric2 psutil pandas faker toml > /dev/null
pip3 install taospy > /dev/null
Expand All @@ -193,6 +201,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
run: |
if [ -f ~/taosdump-failed.txt ]; then
cat ~/taosdump-failed.txt;
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/2.x-macos-debug.yml
Expand Up @@ -73,8 +73,8 @@ jobs:
- name: Checkout TDengine's taos-tools to PR number
if: |
github.event_name == 'pull_request' &&
steps.changed-files-specific.outputs.any_changed == 'true'
(github.event_name == 'pull_request'
&& steps.changed-files-specific.outputs.any_changed == 'true')
run: |
cd TDengine/src/kit/taos-tools
git fetch origin +refs/pull/${{env.PR_NUMBER}}/merge
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/2.x-macos-release.yml
Expand Up @@ -73,8 +73,8 @@ jobs:
- name: Checkout TDengine's taos-tools to PR number
if: |
github.event_name == 'pull_request' &&
steps.changed-files-specific.outputs.any_changed == 'true'
(github.event_name == 'pull_request'
&& steps.changed-files-specific.outputs.any_changed == 'true')
run: |
cd TDengine/src/kit/taos-tools
git fetch origin +refs/pull/${{env.PR_NUMBER}}/merge
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/2.x-taosbenchmark-debug.yml
Expand Up @@ -73,8 +73,8 @@ jobs:
- name: Checkout TDengine's taos-tools to PR number
if: |
steps.changed-files-specific.outputs.any_changed == 'true' &&
github.event_name == 'pull_request'
(steps.changed-files-specific.outputs.any_changed == 'true' &&
github.event_name == 'pull_request')
run: |
cd TDengine/src/kit/taos-tools
git fetch origin +refs/pull/${{env.PR_NUMBER}}/merge
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/2.x-taosbenchmark-release.yml
Expand Up @@ -73,8 +73,8 @@ jobs:
- name: Checkout TDengine's taos-tools to PR number
if: |
steps.changed-files-specific.outputs.any_changed == 'true' &&
github.event_name == 'pull_request'
(steps.changed-files-specific.outputs.any_changed == 'true'
&& github.event_name == 'pull_request')
run: |
cd TDengine/src/kit/taos-tools
git fetch origin +refs/pull/${{env.PR_NUMBER}}/merge
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/2.x-taosdump-debug.yml
Expand Up @@ -74,8 +74,8 @@ jobs:
- name: Checkout TDengine's taos-tools to PR number
if: |
steps.changed-files-specific.outputs.any_changed == 'true' &&
github.event_name == 'pull_request'
(steps.changed-files-specific.outputs.any_changed == 'true'
&& github.event_name == 'pull_request')
run: |
cd TDengine/src/kit/taos-tools
git fetch origin +refs/pull/${{env.PR_NUMBER}}/merge
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/2.x-taosdump-release.yml
Expand Up @@ -83,8 +83,8 @@ jobs:
- name: Checkout TDengine's taos-tools to PR number
if: |
steps.changed-files-specific.outputs.any_changed == 'true' &&
github.event_name == 'pull_request'
(steps.changed-files-specific.outputs.any_changed == 'true'
&& github.event_name == 'pull_request')
run: |
cd TDengine/src/kit/taos-tools
git fetch origin +refs/pull/${{env.PR_NUMBER}}/merge
Expand Down
6 changes: 4 additions & 2 deletions .github/workflows/2.x-windows-build.yml
Expand Up @@ -60,6 +60,7 @@ jobs:
(steps.changed-files-specific.outputs.any_changed == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
uses: actions/checkout@v2
with:
submodules: recursive
Expand All @@ -69,8 +70,8 @@ jobs:

- name: Checkout TDengine's taos-tools to PR number
if: |
github.event_name == 'pull_request' &&
steps.changed-files-specific.outputs.any_changed == 'true'
(github.event_name == 'pull_request'
&& steps.changed-files-specific.outputs.any_changed == 'true')
run: |
cd TDengine/src/kit/taos-tools
git fetch origin +refs/pull/${{env.PR_NUMBER}}/merge
Expand All @@ -82,6 +83,7 @@ jobs:
(steps.changed-files-specific.outputs.any_changed == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
run: |
choco install jom gawk grep -y
#cd TDengine && mkdir debug && cd debug && cmake .. -G "NMake Makefiles JOM" -DBUILD_JDBC=false -DBUILD_TOOLS=true && jom && jom install
Expand Down
5 changes: 4 additions & 1 deletion .github/workflows/3.0-alpine.yml
Expand Up @@ -78,6 +78,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
uses: jirutka/setup-alpine@v1


Expand All @@ -86,6 +87,7 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
run: |
cat /etc/alpine-release
apk add argp-standalone bash curl cmake gcc make g++ git go procps lsof valgrind linux-headers libunwind libunwind-dev tzdata wget jansson-dev snappy-dev xz-dev zlib-dev
Expand All @@ -96,11 +98,12 @@ jobs:
(needs.check-changed.outputs.changedflag == 'true'
&& github.event_name == 'pull_request')
|| github.event_name == 'push'
|| github.event_name == 'schedule'
shell: alpine.sh --root {0}
run: |
git clone --branch main --depth 1 https://github.com/taosdata/TDengine > /dev/null || exit 1
cd TDengine && mkdir debug && cd debug && cmake .. -DBUILD_TOOLS=true -DTOOLS_BUILD_TYPE=${{env.TOOLS_BUILD_TYPE}} -DBUILD_HTTP=false && make -j8 && make install
cd TDengine && mkdir debug && cd debug && cmake .. -DBUILD_TOOLS=true -DTOOLS_BUILD_TYPE=${{env.TOOLS_BUILD_TYPE}} -DBUILD_HTTP=false && make -j2 && make install
if [[ ! -f /usr/local/taos/bin/taosd ]] || [[ ! -f /usr/local/taos/bin/taos ]]
then
echo "TDengien build failure"
Expand Down

0 comments on commit aa67feb

Please sign in to comment.