Skip to content
This repository has been archived by the owner on Nov 24, 2023. It is now read-only.

Commit

Permalink
integration test: fix invalid pgrep expression which may cause case f…
Browse files Browse the repository at this point in the history
…ail sometime; add sleep to all_mode test(may fail sometimes)
  • Loading branch information
D3Hunter committed Sep 22, 2021
1 parent 08727bc commit 5d1b29a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion tests/_utils/test_prepare
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ function wait_pattern_exit() {
pattern=$1
while true
do
if [ "pgrep -f $pattern" != "0" ]; then
if ! pgrep -f $pattern >/dev/null 2>&1; then
echo "pattern $pattern already exit"
return 0
fi
Expand Down
1 change: 1 addition & 0 deletions tests/all_mode/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -400,6 +400,7 @@ function run() {
"resume-relay -s mysql-replica-01" \
"\"result\": true" 2

sleep 2
# relay should continue pulling from syncer's checkpoint, so only pull the latest binlog
server_uuid=$(tail -n 1 $WORK_DIR/worker1/relay_log/server-uuid.index)
echo "relay logs $(ls $WORK_DIR/worker1/relay_log/$server_uuid)"
Expand Down

0 comments on commit 5d1b29a

Please sign in to comment.