From 9e989aa800cc2374c84c16428cf01d01b3ec6c07 Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Thu, 15 Oct 2020 15:16:09 +0100 Subject: [PATCH 01/16] [CI][flaky] reporting --- Jenkinsfile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index f3618d6615f..5207208553b 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -126,7 +126,9 @@ pipeline { runbld(stashedTestReports: stashedTestReports, project: env.REPO) } cleanup { - notifyBuildResult(prComment: true, slackComment: true, slackNotify: (isBranch() || isTag())) + notifyBuildResult(prComment: true, + slackComment: true, slackNotify: (isBranch() || isTag()) + analyzeFlakey: true, flakyReportIdx: "reporter-beats-pipeline-master") } } } From 446299bccd54a46b8e52efab7ff38648acb1f873 Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Thu, 15 Oct 2020 16:01:21 +0100 Subject: [PATCH 02/16] Use the right indice --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 5207208553b..ba76a085889 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -128,7 +128,7 @@ pipeline { cleanup { notifyBuildResult(prComment: true, slackComment: true, slackNotify: (isBranch() || isTag()) - analyzeFlakey: true, flakyReportIdx: "reporter-beats-pipeline-master") + analyzeFlakey: true, flakyReportIdx: "reporter-beats-beats-master") } } } From 970eafc37b5c341c25af35df506e8937197ad24e Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Thu, 15 Oct 2020 16:48:33 +0100 Subject: [PATCH 03/16] Fix missing comma --- Jenkinsfile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index ba76a085889..5caa89baf85 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -126,8 +126,9 @@ pipeline { runbld(stashedTestReports: stashedTestReports, project: env.REPO) } cleanup { + // TODO analyzeFlakey does not support other release branches but the master branch. notifyBuildResult(prComment: true, - slackComment: true, slackNotify: (isBranch() || isTag()) + slackComment: true, slackNotify: (isBranch() || isTag()), analyzeFlakey: true, flakyReportIdx: "reporter-beats-beats-master") } } From c6957e69d585e576e1774d337201e2b768b53b89 Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Thu, 22 Oct 2020 14:31:39 +0100 Subject: [PATCH 04/16] Force test failure in an existing flaky test --- .../elastic-agent/pkg/agent/application/fleet_gateway_test.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/x-pack/elastic-agent/pkg/agent/application/fleet_gateway_test.go b/x-pack/elastic-agent/pkg/agent/application/fleet_gateway_test.go index cfcd1f46994..4c4b9170ea4 100644 --- a/x-pack/elastic-agent/pkg/agent/application/fleet_gateway_test.go +++ b/x-pack/elastic-agent/pkg/agent/application/fleet_gateway_test.go @@ -162,7 +162,7 @@ func wrapStrToResp(code int, body string) *http.Response { } func TestFleetGateway(t *testing.T) { - + t.Fatal("for testing the flaky test reporting for an existing flaky test") agentInfo := &testAgentInfo{} settings := &fleetGatewaySettings{ Duration: 5 * time.Second, @@ -379,6 +379,7 @@ func TestFleetGateway(t *testing.T) { } func TestRetriesOnFailures(t *testing.T) { + t.Fatal("for testing the flaky test reporting for an existing flaky test") agentInfo := &testAgentInfo{} settings := &fleetGatewaySettings{ Duration: 5 * time.Second, From ba9957b5f890ee7ca6a578fad01c43a56aaa8acc Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Thu, 22 Oct 2020 16:53:12 +0100 Subject: [PATCH 05/16] Add debug logs --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 16d29aaef28..e08a3b0ca56 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,6 +1,6 @@ #!/usr/bin/env groovy -@Library('apm@current') _ +@Library('apm@feature/debug') _ import groovy.transform.Field /** From 6e6e094601aee8bea2822fced9073bdb4bc1b64d Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Thu, 22 Oct 2020 18:52:41 +0100 Subject: [PATCH 06/16] chore: for testing purposes --- Jenkinsfile | 2 +- Jenkinsfile.yml | 34 +++++++++++++++++----------------- 2 files changed, 18 insertions(+), 18 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index e08a3b0ca56..54f1f3bff4f 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -76,7 +76,7 @@ pipeline { withGithubNotify(context: 'Lint') { withBeatsEnv(archive: false, id: 'lint') { dumpVariables() - cmd(label: 'make check', script: 'make check') + //cmd(label: 'make check', script: 'make check') } } } diff --git a/Jenkinsfile.yml b/Jenkinsfile.yml index f7b21e1cbdf..b89d9c54b76 100644 --- a/Jenkinsfile.yml +++ b/Jenkinsfile.yml @@ -1,22 +1,22 @@ projects: - - "auditbeat" - - "deploy/kubernetes" - - "filebeat" - - "generator" - - "heartbeat" - - "journalbeat" - - "libbeat" - - "metricbeat" - - "packetbeat" - - "winlogbeat" - - "x-pack/auditbeat" - - "x-pack/dockerlogbeat" + #- "auditbeat" + #- "deploy/kubernetes" + #- "filebeat" + #- "generator" + #- "heartbeat" + #- "journalbeat" + #- "libbeat" + #- "metricbeat" + #- "packetbeat" + #- "winlogbeat" + #- "x-pack/auditbeat" + #- "x-pack/dockerlogbeat" - "x-pack/elastic-agent" - - "x-pack/filebeat" - - "x-pack/functionbeat" - - "x-pack/libbeat" - - "x-pack/metricbeat" - - "x-pack/winlogbeat" + #- "x-pack/filebeat" + #- "x-pack/functionbeat" + #- "x-pack/libbeat" + #- "x-pack/metricbeat" + #- "x-pack/winlogbeat" ##- "x-pack/heartbeat" It's not yet in the 1.0 pipeline. ##- "x-pack/journalbeat" It's not yet in the 1.0 pipeline. ##- "x-pack/packetbeat" It's not yet in the 1.0 pipeline. From 3a701bddc6e0c1310baca8f0c254b99299be49c4 Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Thu, 22 Oct 2020 21:24:11 +0100 Subject: [PATCH 07/16] Force flaky failures for filebeat and libbeat MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Build and Test / Filebeat Windows / test_close_renamed – test_harvester.Test Oct 21, 2020 @ 04:00:25.019 Build and Test / Libbeat / Libbeat oss / TestClientPublishEventKerberosAware – elasticsearch --- Jenkinsfile.yml | 6 +- filebeat/Jenkinsfile.yml | 80 +++++++++---------- filebeat/tests/system/test_harvester.py | 1 + libbeat/Jenkinsfile.yml | 30 +++---- .../elasticsearch/client_integration_test.go | 1 + 5 files changed, 60 insertions(+), 58 deletions(-) diff --git a/Jenkinsfile.yml b/Jenkinsfile.yml index b89d9c54b76..5f61776400e 100644 --- a/Jenkinsfile.yml +++ b/Jenkinsfile.yml @@ -1,17 +1,17 @@ projects: #- "auditbeat" #- "deploy/kubernetes" - #- "filebeat" + - "filebeat" #- "generator" #- "heartbeat" #- "journalbeat" - #- "libbeat" + - "libbeat" #- "metricbeat" #- "packetbeat" #- "winlogbeat" #- "x-pack/auditbeat" #- "x-pack/dockerlogbeat" - - "x-pack/elastic-agent" + #- "x-pack/elastic-agent" #- "x-pack/filebeat" #- "x-pack/functionbeat" #- "x-pack/libbeat" diff --git a/filebeat/Jenkinsfile.yml b/filebeat/Jenkinsfile.yml index 09dbe948c72..4dab3143e3a 100644 --- a/filebeat/Jenkinsfile.yml +++ b/filebeat/Jenkinsfile.yml @@ -13,47 +13,47 @@ when: tags: true ## for all the tags platform: "linux && ubuntu-18" ## default label for all the stages stages: - arm: - mage: "mage build unitTest" - platforms: ## override default label in this specific stage. - - "arm" - when: ## Override the top-level when. - comments: - - "/test filebeat for arm" - labels: - - "arm" - parameters: - - "armTest" - branches: true ## for all the branches - tags: true ## for all the tags - build: - mage: "mage build test" - withModule: true ## run the ITs only if the changeset affects a specific module. - macos: - mage: "mage build unitTest" - platforms: ## override default label in this specific stage. - - "macosx" - when: ## Override the top-level when. - comments: - - "/test filebeat for macos" - labels: - - "macOS" - parameters: - - "macosTest" - branches: true ## for all the branches - tags: true ## for all the tags + #arm: + # mage: "mage build unitTest" + # platforms: ## override default label in this specific stage. + # - "arm" + # when: ## Override the top-level when. + # comments: + # - "/test filebeat for arm" + # labels: + # - "arm" + # parameters: + # - "armTest" + # branches: true ## for all the branches + # tags: true ## for all the tags + #build: + # mage: "mage build test" + # withModule: true ## run the ITs only if the changeset affects a specific module. + #macos: + # mage: "mage build unitTest" + # platforms: ## override default label in this specific stage. + # - "macosx" + # when: ## Override the top-level when. + # comments: + # - "/test filebeat for macos" + # labels: + # - "macOS" + # parameters: + # - "macosTest" + # branches: true ## for all the branches + # tags: true ## for all the tags windows: mage: "mage build unitTest" platforms: ## override default labels in this specific stage. - "windows-2019" - windows-2016: - mage: "mage build unitTest" - platforms: ## override default labels in this specific stage. - - "windows-2016" - when: ## Override the top-level when. - comments: - - "/test filebeat for windows-2016" - labels: - - "windows-2016" - branches: true ## for all the branches - tags: true ## for all the tags + #windows-2016: + # mage: "mage build unitTest" + # platforms: ## override default labels in this specific stage. + # - "windows-2016" + # when: ## Override the top-level when. + # comments: + # - "/test filebeat for windows-2016" + # labels: + # - "windows-2016" + # branches: true ## for all the branches + # tags: true ## for all the tags diff --git a/filebeat/tests/system/test_harvester.py b/filebeat/tests/system/test_harvester.py index cb30dc4976b..ea91c478f73 100644 --- a/filebeat/tests/system/test_harvester.py +++ b/filebeat/tests/system/test_harvester.py @@ -18,6 +18,7 @@ class Test(BaseTest): def test_close_renamed(self): + t.Fatal("for testing the flaky test reporting for an existing flaky test") """ Checks that a file is closed when its renamed / rotated """ diff --git a/libbeat/Jenkinsfile.yml b/libbeat/Jenkinsfile.yml index 692400e7253..a58e22fdfab 100644 --- a/libbeat/Jenkinsfile.yml +++ b/libbeat/Jenkinsfile.yml @@ -12,20 +12,20 @@ when: tags: true ## for all the tags platform: "linux && ubuntu-18" ## default label for all the stages stages: - arm: - mage: "mage build unitTest" - platforms: ## override default label in this specific stage. - - "arm" - when: ## Override the top-level when. - comments: - - "/test libbeat for arm" - labels: - - "arm" - parameters: - - "armTest" + #arm: + # mage: "mage build unitTest" + # platforms: ## override default label in this specific stage. + # - "arm" + # when: ## Override the top-level when. + # comments: + # - "/test libbeat for arm" + # labels: + # - "arm" + # parameters: + # - "armTest" build: mage: "mage build test" - crosscompile: - make: "make -C libbeat crosscompile" - stress-tests: - make: "make STRESS_TEST_OPTIONS='-timeout=20m -race -v -parallel 1' -C libbeat stress-tests" + #crosscompile: + # make: "make -C libbeat crosscompile" + #stress-tests: + # make: "make STRESS_TEST_OPTIONS='-timeout=20m -race -v -parallel 1' -C libbeat stress-tests" diff --git a/libbeat/outputs/elasticsearch/client_integration_test.go b/libbeat/outputs/elasticsearch/client_integration_test.go index 67ccc34b8f7..9870f5de7a5 100644 --- a/libbeat/outputs/elasticsearch/client_integration_test.go +++ b/libbeat/outputs/elasticsearch/client_integration_test.go @@ -55,6 +55,7 @@ func TestClientPublishEvent(t *testing.T) { } func TestClientPublishEventKerberosAware(t *testing.T) { + t.Fatal("for testing the flaky test reporting for an existing flaky test") t.Skip("Flaky test: https://github.com/elastic/beats/issues/21295") err := setupRoleMapping(t, eslegtest.GetEsKerberosHost()) From 2ec9d4a729f7a6836ce708a6d163f9e3b1ab2ff9 Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Mon, 26 Oct 2020 14:15:06 +0000 Subject: [PATCH 08/16] chore: for testing purposes --- Jenkinsfile.yml | 4 ++-- metricbeat/module/windows/service/reader_test.go | 1 + metricbeat/module/windows/service/service_status_test.go | 1 + 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/Jenkinsfile.yml b/Jenkinsfile.yml index 5f61776400e..117766932a5 100644 --- a/Jenkinsfile.yml +++ b/Jenkinsfile.yml @@ -5,8 +5,8 @@ projects: #- "generator" #- "heartbeat" #- "journalbeat" - - "libbeat" - #- "metricbeat" + #- "libbeat" + - "metricbeat" #- "packetbeat" #- "winlogbeat" #- "x-pack/auditbeat" diff --git a/metricbeat/module/windows/service/reader_test.go b/metricbeat/module/windows/service/reader_test.go index 0d2cb7d7e03..aa72e18ab92 100644 --- a/metricbeat/module/windows/service/reader_test.go +++ b/metricbeat/module/windows/service/reader_test.go @@ -55,6 +55,7 @@ func TestGetMachineGUID(t *testing.T) { } func TestRead(t *testing.T) { + t.Fatal("for testing the flaky test reporting for an existing flaky test") reader, err := NewReader() assert.NoError(t, err) result, err := reader.Read() diff --git a/metricbeat/module/windows/service/service_status_test.go b/metricbeat/module/windows/service/service_status_test.go index 667632abf4c..3ba2c3b0c57 100644 --- a/metricbeat/module/windows/service/service_status_test.go +++ b/metricbeat/module/windows/service/service_status_test.go @@ -26,6 +26,7 @@ import ( ) func TestGetServiceStates(t *testing.T) { + t.Fatal("for testing the flaky test reporting for an existing flaky test") handle, err := openSCManager("", "", ScManagerEnumerateService|ScManagerConnect) assert.NoError(t, err) assert.NotEqual(t, handle, InvalidDatabaseHandle) From 5532351dd3222ab233a6cb2723880f7f04eaf062 Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Mon, 26 Oct 2020 18:20:26 +0000 Subject: [PATCH 09/16] chore: for testing purposes --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 54f1f3bff4f..c0216a3a3bf 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -20,7 +20,7 @@ pipeline { JOB_GCS_BUCKET = 'beats-ci-temp' JOB_GCS_CREDENTIALS = 'beats-ci-gcs-plugin' OSS_MODULE_PATTERN = '^[a-z0-9]+beat\\/module\\/([^\\/]+)\\/.*' - PIPELINE_LOG_LEVEL = 'INFO' + PIPELINE_LOG_LEVEL = 'DEBUG' PYTEST_ADDOPTS = "${params.PYTEST_ADDOPTS}" RUNBLD_DISABLE_NOTIFICATIONS = 'true' SLACK_CHANNEL = "#beats-build" From f45b2725215bae879211969a190fea742fece507 Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Mon, 26 Oct 2020 19:38:13 +0000 Subject: [PATCH 10/16] Use the workspace where to run the notifyBuildResult --- Jenkinsfile | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index c0216a3a3bf..4e10404f496 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -126,10 +126,13 @@ pipeline { runbld(stashedTestReports: stashedTestReports, project: env.REPO) } cleanup { - // TODO analyzeFlakey does not support other release branches but the master branch. - notifyBuildResult(prComment: true, - slackComment: true, slackNotify: (isBranch() || isTag()), - analyzeFlakey: true, flakyReportIdx: "reporter-beats-beats-master") + // Required to enable the flaky test reporting with GitHub. Workspace exists since the post/always runs earlier + dir("${BASE_DIR}"){ + // TODO analyzeFlakey does not support other release branches but the master branch. + notifyBuildResult(prComment: true, + slackComment: true, slackNotify: (isBranch() || isTag()), + analyzeFlakey: true, flakyReportIdx: "reporter-beats-beats-master") + } } } } From 7753860f51f0b1df11660bb04987c1ed4013f1aa Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Tue, 27 Oct 2020 12:02:31 +0000 Subject: [PATCH 11/16] Revert "chore: for testing purposes" This reverts commit 5532351dd3222ab233a6cb2723880f7f04eaf062. --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 4e10404f496..0714b02b014 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -20,7 +20,7 @@ pipeline { JOB_GCS_BUCKET = 'beats-ci-temp' JOB_GCS_CREDENTIALS = 'beats-ci-gcs-plugin' OSS_MODULE_PATTERN = '^[a-z0-9]+beat\\/module\\/([^\\/]+)\\/.*' - PIPELINE_LOG_LEVEL = 'DEBUG' + PIPELINE_LOG_LEVEL = 'INFO' PYTEST_ADDOPTS = "${params.PYTEST_ADDOPTS}" RUNBLD_DISABLE_NOTIFICATIONS = 'true' SLACK_CHANNEL = "#beats-build" From 35a3b64c0d7aab94c56c1b8819981c3e6f5e01fc Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Tue, 27 Oct 2020 12:02:41 +0000 Subject: [PATCH 12/16] Revert "chore: for testing purposes" This reverts commit 2ec9d4a729f7a6836ce708a6d163f9e3b1ab2ff9. --- Jenkinsfile.yml | 4 ++-- metricbeat/module/windows/service/reader_test.go | 1 - metricbeat/module/windows/service/service_status_test.go | 1 - 3 files changed, 2 insertions(+), 4 deletions(-) diff --git a/Jenkinsfile.yml b/Jenkinsfile.yml index 117766932a5..5f61776400e 100644 --- a/Jenkinsfile.yml +++ b/Jenkinsfile.yml @@ -5,8 +5,8 @@ projects: #- "generator" #- "heartbeat" #- "journalbeat" - #- "libbeat" - - "metricbeat" + - "libbeat" + #- "metricbeat" #- "packetbeat" #- "winlogbeat" #- "x-pack/auditbeat" diff --git a/metricbeat/module/windows/service/reader_test.go b/metricbeat/module/windows/service/reader_test.go index aa72e18ab92..0d2cb7d7e03 100644 --- a/metricbeat/module/windows/service/reader_test.go +++ b/metricbeat/module/windows/service/reader_test.go @@ -55,7 +55,6 @@ func TestGetMachineGUID(t *testing.T) { } func TestRead(t *testing.T) { - t.Fatal("for testing the flaky test reporting for an existing flaky test") reader, err := NewReader() assert.NoError(t, err) result, err := reader.Read() diff --git a/metricbeat/module/windows/service/service_status_test.go b/metricbeat/module/windows/service/service_status_test.go index 3ba2c3b0c57..667632abf4c 100644 --- a/metricbeat/module/windows/service/service_status_test.go +++ b/metricbeat/module/windows/service/service_status_test.go @@ -26,7 +26,6 @@ import ( ) func TestGetServiceStates(t *testing.T) { - t.Fatal("for testing the flaky test reporting for an existing flaky test") handle, err := openSCManager("", "", ScManagerEnumerateService|ScManagerConnect) assert.NoError(t, err) assert.NotEqual(t, handle, InvalidDatabaseHandle) From f6a441d1bcd24204c6ad103937fc5adad91d115f Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Tue, 27 Oct 2020 12:04:47 +0000 Subject: [PATCH 13/16] Revert "Force flaky failures for filebeat and libbeat" This reverts commit 3a701bddc6e0c1310baca8f0c254b99299be49c4. --- Jenkinsfile.yml | 6 +- filebeat/Jenkinsfile.yml | 84 +++++++++---------- filebeat/tests/system/test_harvester.py | 1 - libbeat/Jenkinsfile.yml | 30 +++---- .../elasticsearch/client_integration_test.go | 1 - 5 files changed, 59 insertions(+), 63 deletions(-) diff --git a/Jenkinsfile.yml b/Jenkinsfile.yml index 5f61776400e..b89d9c54b76 100644 --- a/Jenkinsfile.yml +++ b/Jenkinsfile.yml @@ -1,17 +1,17 @@ projects: #- "auditbeat" #- "deploy/kubernetes" - - "filebeat" + #- "filebeat" #- "generator" #- "heartbeat" #- "journalbeat" - - "libbeat" + #- "libbeat" #- "metricbeat" #- "packetbeat" #- "winlogbeat" #- "x-pack/auditbeat" #- "x-pack/dockerlogbeat" - #- "x-pack/elastic-agent" + - "x-pack/elastic-agent" #- "x-pack/filebeat" #- "x-pack/functionbeat" #- "x-pack/libbeat" diff --git a/filebeat/Jenkinsfile.yml b/filebeat/Jenkinsfile.yml index e843abce685..d2e1d866526 100644 --- a/filebeat/Jenkinsfile.yml +++ b/filebeat/Jenkinsfile.yml @@ -13,50 +13,50 @@ when: tags: true ## for all the tags platform: "linux && ubuntu-18" ## default label for all the stages stages: - #arm: - # mage: "mage build unitTest" - # platforms: ## override default label in this specific stage. - # - "arm" - # when: ## Override the top-level when. - # comments: - # - "/test filebeat for arm" - # labels: - # - "arm" - # parameters: - # - "armTest" - # branches: true ## for all the branches - # tags: true ## for all the tags - #build: - # mage: "mage build test" - # withModule: true ## run the ITs only if the changeset affects a specific module. - #macos: - # mage: "mage build unitTest" - # platforms: ## override default label in this specific stage. - # - "macosx" - # when: ## Override the top-level when. - # comments: - # - "/test filebeat for macos" - # labels: - # - "macOS" - # parameters: - # - "macosTest" - # branches: true ## for all the branches - # tags: true ## for all the tags + arm: + mage: "mage build unitTest" + platforms: ## override default label in this specific stage. + - "arm" + when: ## Override the top-level when. + comments: + - "/test filebeat for arm" + labels: + - "arm" + parameters: + - "armTest" + branches: true ## for all the branches + tags: true ## for all the tags + build: + mage: "mage build test" + withModule: true ## run the ITs only if the changeset affects a specific module. + macos: + mage: "mage build unitTest" + platforms: ## override default label in this specific stage. + - "macosx" + when: ## Override the top-level when. + comments: + - "/test filebeat for macos" + labels: + - "macOS" + parameters: + - "macosTest" + branches: true ## for all the branches + tags: true ## for all the tags windows: mage: "mage build unitTest" platforms: ## override default labels in this specific stage. - "windows-2019" - #windows-2016: - # mage: "mage build unitTest" - # platforms: ## override default labels in this specific stage. - # - "windows-2016" - # when: ## Override the top-level when. - # comments: - # - "/test filebeat for windows-2016" - # labels: - # - "windows-2016" - # branches: true ## for all the branches - # tags: true ## for all the tags + windows-2016: + mage: "mage build unitTest" + platforms: ## override default labels in this specific stage. + - "windows-2016" + when: ## Override the top-level when. + comments: + - "/test filebeat for windows-2016" + labels: + - "windows-2016" + branches: true ## for all the branches + tags: true ## for all the tags windows-10: mage: "mage build unitTest" platforms: ## override default labels in this specific stage. @@ -67,6 +67,4 @@ stages: labels: - "windows-10" branches: true ## for all the branches - tags: true ## for all the tags - branches: true ## for all the branches - tags: true ## for all the tags + tags: true ## for all the tags \ No newline at end of file diff --git a/filebeat/tests/system/test_harvester.py b/filebeat/tests/system/test_harvester.py index ea91c478f73..cb30dc4976b 100644 --- a/filebeat/tests/system/test_harvester.py +++ b/filebeat/tests/system/test_harvester.py @@ -18,7 +18,6 @@ class Test(BaseTest): def test_close_renamed(self): - t.Fatal("for testing the flaky test reporting for an existing flaky test") """ Checks that a file is closed when its renamed / rotated """ diff --git a/libbeat/Jenkinsfile.yml b/libbeat/Jenkinsfile.yml index a58e22fdfab..692400e7253 100644 --- a/libbeat/Jenkinsfile.yml +++ b/libbeat/Jenkinsfile.yml @@ -12,20 +12,20 @@ when: tags: true ## for all the tags platform: "linux && ubuntu-18" ## default label for all the stages stages: - #arm: - # mage: "mage build unitTest" - # platforms: ## override default label in this specific stage. - # - "arm" - # when: ## Override the top-level when. - # comments: - # - "/test libbeat for arm" - # labels: - # - "arm" - # parameters: - # - "armTest" + arm: + mage: "mage build unitTest" + platforms: ## override default label in this specific stage. + - "arm" + when: ## Override the top-level when. + comments: + - "/test libbeat for arm" + labels: + - "arm" + parameters: + - "armTest" build: mage: "mage build test" - #crosscompile: - # make: "make -C libbeat crosscompile" - #stress-tests: - # make: "make STRESS_TEST_OPTIONS='-timeout=20m -race -v -parallel 1' -C libbeat stress-tests" + crosscompile: + make: "make -C libbeat crosscompile" + stress-tests: + make: "make STRESS_TEST_OPTIONS='-timeout=20m -race -v -parallel 1' -C libbeat stress-tests" diff --git a/libbeat/outputs/elasticsearch/client_integration_test.go b/libbeat/outputs/elasticsearch/client_integration_test.go index 9870f5de7a5..67ccc34b8f7 100644 --- a/libbeat/outputs/elasticsearch/client_integration_test.go +++ b/libbeat/outputs/elasticsearch/client_integration_test.go @@ -55,7 +55,6 @@ func TestClientPublishEvent(t *testing.T) { } func TestClientPublishEventKerberosAware(t *testing.T) { - t.Fatal("for testing the flaky test reporting for an existing flaky test") t.Skip("Flaky test: https://github.com/elastic/beats/issues/21295") err := setupRoleMapping(t, eslegtest.GetEsKerberosHost()) From 0faff8a37502501b60192e7266243e4e23093555 Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Tue, 27 Oct 2020 12:05:00 +0000 Subject: [PATCH 14/16] Revert "chore: for testing purposes" This reverts commit 6e6e094601aee8bea2822fced9073bdb4bc1b64d. --- Jenkinsfile | 2 +- Jenkinsfile.yml | 34 +++++++++++++++++----------------- 2 files changed, 18 insertions(+), 18 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 0714b02b014..c33ec831c0d 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -76,7 +76,7 @@ pipeline { withGithubNotify(context: 'Lint') { withBeatsEnv(archive: false, id: 'lint') { dumpVariables() - //cmd(label: 'make check', script: 'make check') + cmd(label: 'make check', script: 'make check') } } } diff --git a/Jenkinsfile.yml b/Jenkinsfile.yml index b89d9c54b76..f7b21e1cbdf 100644 --- a/Jenkinsfile.yml +++ b/Jenkinsfile.yml @@ -1,22 +1,22 @@ projects: - #- "auditbeat" - #- "deploy/kubernetes" - #- "filebeat" - #- "generator" - #- "heartbeat" - #- "journalbeat" - #- "libbeat" - #- "metricbeat" - #- "packetbeat" - #- "winlogbeat" - #- "x-pack/auditbeat" - #- "x-pack/dockerlogbeat" + - "auditbeat" + - "deploy/kubernetes" + - "filebeat" + - "generator" + - "heartbeat" + - "journalbeat" + - "libbeat" + - "metricbeat" + - "packetbeat" + - "winlogbeat" + - "x-pack/auditbeat" + - "x-pack/dockerlogbeat" - "x-pack/elastic-agent" - #- "x-pack/filebeat" - #- "x-pack/functionbeat" - #- "x-pack/libbeat" - #- "x-pack/metricbeat" - #- "x-pack/winlogbeat" + - "x-pack/filebeat" + - "x-pack/functionbeat" + - "x-pack/libbeat" + - "x-pack/metricbeat" + - "x-pack/winlogbeat" ##- "x-pack/heartbeat" It's not yet in the 1.0 pipeline. ##- "x-pack/journalbeat" It's not yet in the 1.0 pipeline. ##- "x-pack/packetbeat" It's not yet in the 1.0 pipeline. From e3bc1326cd9752163c8e6de1304b498fc5a90f1c Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Tue, 27 Oct 2020 12:05:29 +0000 Subject: [PATCH 15/16] Revert "Add debug logs" This reverts commit ba9957b5f890ee7ca6a578fad01c43a56aaa8acc. --- Jenkinsfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index c33ec831c0d..edcc910db04 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,6 +1,6 @@ #!/usr/bin/env groovy -@Library('apm@feature/debug') _ +@Library('apm@current') _ import groovy.transform.Field /** From df4057f64814bd47d7f2fa2051fa3b7368a1ddf1 Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Tue, 27 Oct 2020 12:05:40 +0000 Subject: [PATCH 16/16] Revert "Force test failure in an existing flaky test" This reverts commit c6957e69d585e576e1774d337201e2b768b53b89. --- .../elastic-agent/pkg/agent/application/fleet_gateway_test.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/x-pack/elastic-agent/pkg/agent/application/fleet_gateway_test.go b/x-pack/elastic-agent/pkg/agent/application/fleet_gateway_test.go index 4c4b9170ea4..cfcd1f46994 100644 --- a/x-pack/elastic-agent/pkg/agent/application/fleet_gateway_test.go +++ b/x-pack/elastic-agent/pkg/agent/application/fleet_gateway_test.go @@ -162,7 +162,7 @@ func wrapStrToResp(code int, body string) *http.Response { } func TestFleetGateway(t *testing.T) { - t.Fatal("for testing the flaky test reporting for an existing flaky test") + agentInfo := &testAgentInfo{} settings := &fleetGatewaySettings{ Duration: 5 * time.Second, @@ -379,7 +379,6 @@ func TestFleetGateway(t *testing.T) { } func TestRetriesOnFailures(t *testing.T) { - t.Fatal("for testing the flaky test reporting for an existing flaky test") agentInfo := &testAgentInfo{} settings := &fleetGatewaySettings{ Duration: 5 * time.Second,