You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flink.apache.org by ch...@apache.org on 2019/05/15 11:47:49 UTC
[flink] branch master updated: [FLINK-12463][tests] Deduplicate
empty .out log file checks
This is an automated email from the ASF dual-hosted git repository.
chesnay pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/flink.git
The following commit(s) were added to refs/heads/master by this push:
new f8f98ef [FLINK-12463][tests] Deduplicate empty .out log file checks
f8f98ef is described below
commit f8f98ef2ae6f71c88f158a22146f148464d61fba
Author: Chesnay Schepler <ch...@apache.org>
AuthorDate: Wed May 8 11:59:27 2019 +0200
[FLINK-12463][tests] Deduplicate empty .out log file checks
---
flink-end-to-end-tests/test-scripts/common_ha.sh | 5 +++--
.../test-scripts/test_ha_per_job_cluster_datastream.sh | 3 +--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/flink-end-to-end-tests/test-scripts/common_ha.sh b/flink-end-to-end-tests/test-scripts/common_ha.sh
index 6521cb4..59e8c8c 100644
--- a/flink-end-to-end-tests/test-scripts/common_ha.sh
+++ b/flink-end-to-end-tests/test-scripts/common_ha.sh
@@ -18,6 +18,8 @@
# limitations under the License.
################################################################################
+source "${END_TO_END_DIR}"/test-scripts/common.sh
+
# flag indicating if we have already cleared up things after a test
CLEARED=0
@@ -53,13 +55,12 @@ function verify_num_occurences_in_logs() {
}
function verify_logs() {
- local OUTPUT=$FLINK_DIR/log/*.out
local JM_FAILURES=$1
local EXIT_CODE=0
local VERIFY_CHECKPOINTS=$2
# verify that we have no alerts
- if ! [ `cat ${OUTPUT} | wc -l` -eq 0 ]; then
+ if ! check_logs_for_non_empty_out_files; then
echo "FAILURE: Alerts found at the general purpose job."
EXIT_CODE=1
fi
diff --git a/flink-end-to-end-tests/test-scripts/test_ha_per_job_cluster_datastream.sh b/flink-end-to-end-tests/test-scripts/test_ha_per_job_cluster_datastream.sh
index 61dd8bc..1dbb762 100755
--- a/flink-end-to-end-tests/test-scripts/test_ha_per_job_cluster_datastream.sh
+++ b/flink-end-to-end-tests/test-scripts/test_ha_per_job_cluster_datastream.sh
@@ -64,12 +64,11 @@ function run_job() {
}
function verify_logs_per_job() {
- local OUTPUT=$FLINK_DIR/log/*.out
local JM_FAILURES=$1
local EXIT_CODE=0
# verify that we have no alerts
- if ! [ `cat ${OUTPUT} | wc -l` -eq 0 ]; then
+ if ! check_logs_for_non_empty_out_files; then
echo "FAILURE: Alerts found at the general purpose job."
EXIT_CODE=1
fi