diff --git a/jenkins/integ-test-notification.jenkinsfile b/jenkins/integ-test-notification.jenkinsfile
new file mode 100644
index 0000000000..450f52aa68
--- /dev/null
+++ b/jenkins/integ-test-notification.jenkinsfile
@@ -0,0 +1,54 @@
+/*
+ * Copyright OpenSearch Contributors
+ * SPDX-License-Identifier: Apache-2.0
+ *
+ * The OpenSearch Contributors require contributions made to
+ * this file be licensed under the Apache-2.0 license or a
+ * compatible open source license.
+ */
+
+lib = library(identifier: 'jenkins@7.0.0', retriever: modernSCM([
+ $class: 'GitSCMSource',
+ remote: 'https://github.com/opensearch-project/opensearch-build-libraries.git',
+]))
+
+
+pipeline {
+ agent { label 'Jenkins-Agent-AL2023-X64-C54xlarge-Docker-Host' }
+ options {
+ timeout(time: 1, unit: 'HOURS')
+ buildDiscarder(logRotator(daysToKeepStr: '90'))
+ }
+ triggers {
+ parameterizedCron('''
+ H */6 * * * %INPUT_MANIFEST=2.17.2/opensearch-2.17.2.yml
+ H */6 * * * %INPUT_MANIFEST=2.18.0/opensearch-2.18.0.yml
+ H */6 * * * %INPUT_MANIFEST=3.0.0/opensearch-3.0.0.yml
+ ''')
+ }
+ parameters {
+ string(
+ name: 'INPUT_MANIFEST',
+ description: 'Input manifest under the manifests folder, e.g. 2.0.0/opensearch-2.0.0.yml.',
+ trim: true
+ )
+ }
+ stages {
+ stage('Update integ tests failure issues') {
+ steps {
+ script {
+ updateIntegTestFailureIssues(
+ inputManifestPath: "manifests/${INPUT_MANIFEST}"
+ )
+ }
+ }
+ }
+ }
+ post() {
+ always {
+ script {
+ postCleanup()
+ }
+ }
+ }
+}
diff --git a/jenkins/opensearch-dashboards/integ-test.jenkinsfile b/jenkins/opensearch-dashboards/integ-test.jenkinsfile
index 68736dd37a..1aafad5716 100644
--- a/jenkins/opensearch-dashboards/integ-test.jenkinsfile
+++ b/jenkins/opensearch-dashboards/integ-test.jenkinsfile
@@ -66,11 +66,6 @@ pipeline {
description: 'The build manifest URL OpenSearch, e.g. "https://ci.opensearch.org/ci/dbc/distribution-build-opensearch/2.9.0/8172/linux/x64/tar/builds/opensearch/manifest.yml".',
trim: true
)
- booleanParam(
- name: 'UPDATE_GITHUB_ISSUES',
- description: 'If true results will create / update / close github issues',
- defaultValue: false
- )
string(
name: 'RC_NUMBER',
description: 'The RC build count. Default is 0 which means its not an RC build.',
@@ -292,32 +287,8 @@ pipeline {
localPath: "${WORKSPACE}/${distribution}",
switchUserNonRoot: "${switch_user_non_root}"
)
- if (params.UPDATE_GITHUB_ISSUES) {
- updateGitHubIssueLabels(
- repoUrl: buildManifestObj.getRepo("${local_component}"),
- issueTitle: "[AUTOCUT] Integration Test failed for ${local_component}: ${version}",
- label: "${platform}:${distribution}:${architecture}",
- action: "remove"
- )
- }
}
} catch (e) {
- echo "Error running integtest for component ${local_component}, creating Github issue"
- String issueBodyMessage = "The integration test failed at distribution level for component ${local_component}
Version: ${version}
Distribution: ${distribution}
Architecture: ${architecture}
Platform: ${platform}
Please check the logs: ${RUN_DISPLAY_URL}
* Test-report manifest:*
- https://ci.opensearch.org/ci/dbc/${JOB_NAME}/${version}/${buildId}/${platform}/${architecture}/${distribution}/test-results/${BUILD_NUMBER}/integ-test/test-report.yml
_Note: Steps to reproduce, additional logs and other files can be found within the above test-report manifest.
Instructions of this test-report manifest can be found [here](https://github.com/opensearch-project/opensearch-build/tree/main/src/report_workflow#guide-on-test-report-manifest-from-ci)._"
- if (params.UPDATE_GITHUB_ISSUES) {
- createGithubIssue(
- repoUrl: buildManifestObj.getRepo("${local_component}"),
- issueTitle: "[AUTOCUT] Integration Test failed for ${local_component}: ${version}",
- issueBody: issueBodyMessage,
- label: "autocut,v${version}"
- )
- updateGitHubIssueLabels(
- repoUrl: buildManifestObj.getRepo("${local_component}"),
- issueTitle: "[AUTOCUT] Integration Test failed for ${local_component}: ${version}",
- label: "integ-test-failure,${platform}:${distribution}:${architecture}",
- action: "add"
- )
- }
throw new Exception("Error running integtest for component ${local_component}", e)
} finally {
echo "Completed running integtest for component ${local_component}"
@@ -388,36 +359,10 @@ pipeline {
}
}
}
-
post {
- success {
+ always {
node(AGENT_LABEL) {
script {
- def stashed = lib.jenkins.Messages.new(this).get(['integ-test'])
- publishNotification(
- icon: ':white_check_mark:',
- message: 'Integration Tests Successful',
- extra: stashed,
- credentialsId: 'jenkins-integ-test-webhook',
- manifest: TEST_MANIFEST,
- )
-
- postCleanup()
- }
- }
- }
- failure {
- node(AGENT_LABEL) {
- script {
- def stashed = lib.jenkins.Messages.new(this).get(['integ-test'])
- publishNotification(
- icon: ':warning:',
- message: 'Failed Integration Tests',
- extra: stashed,
- credentialsId: 'jenkins-integ-test-webhook',
- manifest: TEST_MANIFEST,
- )
-
postCleanup()
}
}
diff --git a/jenkins/opensearch/integ-test.jenkinsfile b/jenkins/opensearch/integ-test.jenkinsfile
index 96cb1dc5fb..7183a9677a 100644
--- a/jenkins/opensearch/integ-test.jenkinsfile
+++ b/jenkins/opensearch/integ-test.jenkinsfile
@@ -66,11 +66,6 @@ pipeline {
description: 'The build manifest URL for OpenSearch, e.g. "https://ci.opensearch.org/ci/dbc/distribution-build-opensearch/2.9.0/8172/linux/x64/tar/builds/opensearch/manifest.yml".',
trim: true
)
- booleanParam(
- name: 'UPDATE_GITHUB_ISSUES',
- description: 'If true results will create / update / close github issues',
- defaultValue: false
- )
string(
name: 'RC_NUMBER',
description: 'The RC build count. Default is 0 which means its not an RC build.',
@@ -254,32 +249,8 @@ pipeline {
localPath: "${WORKSPACE}/${distribution}",
switchUserNonRoot: "${switch_user_non_root}"
)
- if (params.UPDATE_GITHUB_ISSUES) {
- updateGitHubIssueLabels(
- repoUrl: buildManifestObj.getRepo("${local_component}"),
- issueTitle: "[AUTOCUT] Integration Test failed for ${local_component}: ${version}",
- label: "${platform}:${distribution}:${architecture}",
- action: "remove"
- )
- }
}
} catch (e) {
- echo "Error running integtest for component ${local_component}, creating Github issue"
- String issueBodyMessage = "The integration test failed at distribution level for component ${local_component}
Version: ${version}
Distribution: ${distribution}
Architecture: ${architecture}
Platform: ${platform}
Please check the logs: ${RUN_DISPLAY_URL}
* Test-report manifest:*
- https://ci.opensearch.org/ci/dbc/${JOB_NAME}/${version}/${buildId}/${platform}/${architecture}/${distribution}/test-results/${BUILD_NUMBER}/integ-test/test-report.yml
_Note: Steps to reproduce, additional logs and other files can be found within the above test-report manifest.
Instructions of this test-report manifest can be found [here](https://github.com/opensearch-project/opensearch-build/tree/main/src/report_workflow#guide-on-test-report-manifest-from-ci)._"
- if (params.UPDATE_GITHUB_ISSUES) {
- createGithubIssue(
- repoUrl: buildManifestObj.getRepo("${local_component}"),
- issueTitle: "[AUTOCUT] Integration Test failed for ${local_component}: ${version}",
- issueBody: issueBodyMessage,
- label: "autocut,v${version}"
- )
- updateGitHubIssueLabels(
- repoUrl: buildManifestObj.getRepo("${local_component}"),
- issueTitle: "[AUTOCUT] Integration Test failed for ${local_component}: ${version}",
- label: "integ-test-failure,${platform}:${distribution}:${architecture}",
- action: "add"
- )
- }
throw new Exception("Error running integtest for component ${local_component}", e)
} finally {
echo "Completed running integtest for component ${local_component}"
@@ -346,36 +317,10 @@ pipeline {
}
}
}
-
post {
- success {
+ always {
node(AGENT_LABEL) {
script {
- def stashed = lib.jenkins.Messages.new(this).get(['integ-test'])
- publishNotification(
- icon: ':white_check_mark:',
- message: 'Integration Tests Successful',
- extra: stashed,
- credentialsId: 'jenkins-integ-test-webhook',
- manifest: TEST_MANIFEST,
- )
-
- postCleanup()
- }
- }
- }
- failure {
- node(AGENT_LABEL) {
- script {
- def stashed = lib.jenkins.Messages.new(this).get(['integ-test'])
- publishNotification(
- icon: ':warning:',
- message: 'Failed Integration Tests',
- extra: stashed,
- credentialsId: 'jenkins-integ-test-webhook',
- manifest: TEST_MANIFEST,
- )
-
postCleanup()
}
}
diff --git a/tests/jenkins/TestOpenSearchDashboardsIntegTest.groovy b/tests/jenkins/TestOpenSearchDashboardsIntegTest.groovy
index d15917fcd7..2d9deacbb7 100644
--- a/tests/jenkins/TestOpenSearchDashboardsIntegTest.groovy
+++ b/tests/jenkins/TestOpenSearchDashboardsIntegTest.groovy
@@ -139,108 +139,6 @@ class TestOpenSearchDashboardsIntegTest extends BuildPipelineTest {
assertJobStatusFailure()
}
- @Test
- void checkGHissueCreation() {
- addParam('UPDATE_GITHUB_ISSUES', true)
- helper.addShMock("date -d \"3 days ago\" +'%Y-%m-%d'") { script ->
- return [stdout: "2023-10-24", exitValue: 0]
- }
- helper.addShMock("""gh issue list --repo https://github.com/opensearch-project/dashboards-visualizations.git -S "[AUTOCUT] Integration Test failed for ganttChartDashboards: 3.0.0 in:title" --label autocut,v3.0.0 --json number --jq '.[0].number'""") { script ->
- return [stdout: "", exitValue: 0]
- }
- helper.addShMock("""gh issue list --repo https://github.com/opensearch-project/dashboards-visualizations.git -S "[AUTOCUT] Integration Test failed for ganttChartDashboards: 3.0.0 in:title is:closed closed:>=2023-10-24" --label autocut,v3.0.0 --json number --jq '.[0].number'""") { script ->
- return [stdout: "", exitValue: 0]
- }
- helper.addShMock('env PATH=$PATH ./test.sh integ-test manifests/tests/jenkins/data/opensearch-dashboards-3.0.0-test.yml --component ganttChartDashboards --test-run-id 215 --paths opensearch=/tmp/workspace/tar opensearch-dashboards=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/215/linux/x64/tar ', '', 1)
- assertThrows(Exception) {
- runScript('jenkins/opensearch-dashboards/integ-test.jenkinsfile')
- }
- assertJobStatusFailure()
- assertThat(getCommandExecutions('sh', 'script'), hasItem("{script=gh issue list --repo https://github.com/opensearch-project/dashboards-observability.git -S \"[AUTOCUT] Integration Test failed for observabilityDashboards: 3.0.0 in:title\" --json number --jq '.[0].number', returnStdout=true}"))
- }
-
- @Test
- void CheckNotClosingGHissue() {
- addParam('UPDATE_GITHUB_ISSUES', true)
- helper.addShMock("date -d \"3 days ago\" +'%Y-%m-%d'") { script ->
- return [stdout: "2023-10-24", exitValue: 0]
- }
- helper.addShMock('env PATH=$PATH ./test.sh integ-test manifests/tests/jenkins/data/opensearch-dashboards-3.0.0-test.yml --component observabilityDashboards --test-run-id 215 --paths opensearch=/tmp/workspace/tar opensearch-dashboards=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/215/linux/x64/tar ', '', 1)
- helper.addShMock('gh issue list --repo https://github.com/opensearch-project/dashboards-visualization.git -S "[AUTOCUT] Integration Test failed for ganttChartDashboards: 3.0.0 in:title" --label autocut,v3.0.0', '', 0)
- assertThrows(Exception) {
- runScript('jenkins/opensearch-dashboards/integ-test.jenkinsfile')
- }
- assertJobStatusFailure()
- runScript('jenkins/opensearch-dashboards/integ-test.jenkinsfile')
- assertThat(getCommandExecutions('sh', 'script'), not(hasItem("{script=gh issue close bbb\nccc -R opensearch-project/dashboards-visualizations --comment \"Closing the issue as the Integration Test passed for ganttChartDashboards
Version: 3.0.0
Distribution: tar
Architecture: x64
Platform: linux
Please check the logs: https://some/url/redirect
*\", returnStdout=true}")))
- }
-
- @Test
- void checkGHexistingIssue() {
- addParam('UPDATE_GITHUB_ISSUES', true)
- helper.addShMock("date -d \"3 days ago\" +'%Y-%m-%d'") { script ->
- return [stdout: "2023-10-24", exitValue: 0]
- }
- helper.addShMock("""gh issue list --repo https://github.com/opensearch-project/dashboards-observability.git -S "[AUTOCUT] Integration Test failed for observabilityDashboards: 3.0.0 in:title is:closed closed:>=2023-10-24" --label autocut,v3.0.0 --json number --jq '.[0].number'""") { script ->
- return [stdout: "", exitValue: 0]
- }
- helper.addShMock("""gh issue list --repo https://github.com/opensearch-project/sql.git -S "[AUTOCUT] Integration Test failed for observabilityDashboards: 3.0.0 in:title" --label autocut,v3.0.0 --json number --jq '.[0].number'""") { script ->
- return [stdout: "22", exitValue: 0]
- }
- helper.addShMock('env PATH=$PATH ./test.sh integ-test manifests/tests/jenkins/data/opensearch-dashboards-3.0.0-test.yml --component observabilityDashboards --test-run-id 215 --paths opensearch=/tmp/workspace/tar opensearch-dashboards=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/215/linux/x64/tar ', '', 1)
- assertThrows(Exception) {
- runScript('jenkins/opensearch-dashboards/integ-test.jenkinsfile')
- }
- assertJobStatusFailure()
- assertThat(getCommandExecutions('println', 'Issue'), hasItem('Issue already exists, adding a comment'))
- assertThat(getCommandExecutions('sh', 'script'), hasItem("{script=gh issue comment bbb\nccc --repo https://github.com/opensearch-project/dashboards-observability.git --body \"The integration test failed at distribution level for component observabilityDashboards
Version: 3.0.0
Distribution: tar
Architecture: x64
Platform: linux
Please check the logs: https://some/url/redirect
* Test-report manifest:*
- https://ci.opensearch.org/ci/dbc/dummy_job/3.0.0/215/linux/x64/tar/test-results/215/integ-test/test-report.yml
_Note: Steps to reproduce, additional logs and other files can be found within the above test-report manifest.
Instructions of this test-report manifest can be found [here](https://github.com/opensearch-project/opensearch-build/tree/main/src/report_workflow#guide-on-test-report-manifest-from-ci)._\", returnStdout=true}"))
- }
-
- @Test
- void checkGHIssueDisable() {
- addParam('COMPONENT_NAME', 'ganttChartDashboards')
- helper.addShMock('env PATH=$PATH ./test.sh integ-test manifests/tests/jenkins/data/opensearch-dashboards-3.0.0-test.yml --component ganttChartDashboards --test-run-id 215 --paths opensearch=/tmp/workspace/tar opensearch-dashboards=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/215/linux/x64/tar ', '', 1)
- assertThrows(Exception) {
- runScript('jenkins/opensearch-dashboards/integ-test.jenkinsfile')
- }
- assertJobStatusFailure()
- assertThat(getCommandExecutions('sh', 'gh issue').size(), equalTo(0))
- }
-
- @Test
- void verifyLabelRemoval() {
- addParam('UPDATE_GITHUB_ISSUES', true)
- helper.addShMock("""gh issue list --repo https://github.com/opensearch-project/dashboards-observability.git -S "[AUTOCUT] Integration Test failed for observabilityDashboards: 3.0.0 in:title" --json number --jq '.[0].number'""") { script ->
- return [stdout: '65', exitValue: 0]
- }
- helper.addShMock("""gh label list --repo https://github.com/opensearch-project/dashboards-observability.git -S linux:tar:x64 --json name --jq '.[0].name'""") { script ->
- return [stdout: 'linux:tar:x64', exitValue: 0]
- }
- helper.addShMock('env PATH=$PATH ./test.sh integ-test manifests/tests/jenkins/data/opensearch-dashboards-3.0.0-test.yml --component observabilityDashboards --test-run-id 215 --paths opensearch=/tmp/workspace/tar opensearch-dashboards=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/215/linux/x64/tar ') { script ->
- return [stdout: 'Completed running integtest for component observabilityDashboards', exitValue: 0]
- }
- runScript('jenkins/opensearch-dashboards/integ-test.jenkinsfile')
- assertThat(getCommandExecutions('sh', 'gh issue'), hasItem('{script=gh issue edit 65 -R https://github.com/opensearch-project/dashboards-observability.git --remove-label \"linux:tar:x64\", returnStdout=true}'))
- }
-
- @Test
- void verifyLabelAddition() {
- addParam('UPDATE_GITHUB_ISSUES', true)
- helper.addShMock('env PATH=$PATH ./test.sh integ-test manifests/tests/jenkins/data/opensearch-dashboards-3.0.0-test.yml --component observabilityDashboards --test-run-id 215 --paths opensearch=/tmp/workspace/tar opensearch-dashboards=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/215/linux/x64/tar ') { script ->
- return [stdout: 'Error running integtest for component observabilityDashboards, creating Github issue', exitValue: 127]}
- helper.addShMock("""gh issue list --repo https://github.com/opensearch-project/dashboards-observability.git -S "[AUTOCUT] Integration Test failed for observabilityDashboards: 3.0.0 in:title" --json number --jq '.[0].number'""") { script ->
- return [stdout: '99', exitValue: 0]
- }
- helper.addShMock("""gh label list --repo https://github.com/opensearch-project/dashboards-observability.git -S linux:tar:x64 --json name --jq '.[0].name'""") { script ->
- return [stdout: 'no labels in opensearch-project/dashboards-observability matched your search', exitValue: 0]
- }
- assertThrows(Exception) {
- runScript('jenkins/opensearch/integ-test.jenkinsfile')
- }
- assertThat(getCommandExecutions('sh', 'label'), hasItem('{script=gh label create linux:tar:x64 --repo https://github.com/opensearch-project/dashboards-observability.git, returnStdout=true}'))
- assertThat(getCommandExecutions('sh', 'gh issue'), hasItem('{script=gh issue edit 99 -R https://github.com/opensearch-project/dashboards-observability.git --add-label \"linux:tar:x64\", returnStdout=true}'))
- }
-
@Test
void whenValidationIsNotChecked() {
addParam('VALIDATE_ARTIFACTS', false)
diff --git a/tests/jenkins/TestOpenSearchIntegTest.groovy b/tests/jenkins/TestOpenSearchIntegTest.groovy
index 2504776966..0538600f22 100644
--- a/tests/jenkins/TestOpenSearchIntegTest.groovy
+++ b/tests/jenkins/TestOpenSearchIntegTest.groovy
@@ -120,103 +120,6 @@ class TestOpenSearchIntegTest extends BuildPipelineTest {
assertThat(getCommandExecutions('echo', 'sql'), hasItem('Skipping tests for sql as is not present in the provided build manifest.'))
}
- @Test
- void checkGHissueCreation() {
- addParam('UPDATE_GITHUB_ISSUES', true)
- helper.addShMock("date -d \"3 days ago\" +'%Y-%m-%d'") { script ->
- return [stdout: "2023-10-24", exitValue: 0]
- }
- helper.addShMock("""env PATH=\$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component k-NN --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar """) { script ->
- return [stdout: "Error running integtest for component k-NN, creating Github issue", exitValue: 1]}
- helper.addShMock("""gh issue list --repo https://github.com/opensearch-project/k-NN.git -S "[AUTOCUT] Integration Test failed for k-NN: 3.0.0 in:title" --json number --jq '.[0].number'""") { script ->
- return [stdout: "", exitValue: 0]
- }
- helper.addShMock("""gh issue list --repo https://github.com/opensearch-project/k-NN.git -S "[AUTOCUT] Integration Test failed for k-NN: 3.0.0 in:title is:closed closed:>=2023-10-24" --json number --jq '.[0].number'""") { script ->
- return [stdout: "", exitValue: 0]
- }
- assertThrows(Exception) {
- runScript('jenkins/opensearch/integ-test.jenkinsfile')
- }
- assertJobStatusFailure()
- assertThat(getCommandExecutions('sh', 'script'), hasItem("""{script=gh issue create --title \"[AUTOCUT] Integration Test failed for k-NN: 3.0.0\" --body \"The integration test failed at distribution level for component k-NN
Version: 3.0.0
Distribution: tar
Architecture: x64
Platform: linux
Please check the logs: https://some/url/redirect
* Test-report manifest:*
- https://ci.opensearch.org/ci/dbc/dummy_job/3.0.0/9010/linux/x64/tar/test-results/234/integ-test/test-report.yml
_Note: Steps to reproduce, additional logs and other files can be found within the above test-report manifest.
Instructions of this test-report manifest can be found [here](https://github.com/opensearch-project/opensearch-build/tree/main/src/report_workflow#guide-on-test-report-manifest-from-ci)._\" --label \"autocut,v3.0.0\" --label \"untriaged\" --repo https://github.com/opensearch-project/k-NN.git, returnStdout=true}"""))
- }
-
- @Test
- void CheckNotClosingGHissue() {
- addParam('UPDATE_GITHUB_ISSUES', true)
- helper.addShMock("date -d \"5 days ago\" +'%Y-%m-%d'") { script ->
- return [stdout: "2023-10-24", exitValue: 0]
- }
- helper.addShMock("""env PATH=\$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component k-NN --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/8184/linux/x64/tar""") { script ->
- return [stdout: "Completed running integtest for component k-NN", exitValue: 0]
- }
- runScript('jenkins/opensearch/integ-test.jenkinsfile')
- assertThat(getCommandExecutions('sh', 'script'), not(hasItem("{script=gh issue close bbb\nccc -R opensearch-project/k-NN --comment \"Closing the issue as the Integration Test passed for k-NN
Version: 3.0.0
Distribution: tar
Architecture: x64
Platform: linux
Please check the logs: https://some/url/redirect
*\", returnStdout=true}")))
- }
-
- @Test
- void checkGHexistingIssue() {
- addParam('UPDATE_GITHUB_ISSUES', true)
- helper.addShMock("date -d \"3 days ago\" +'%Y-%m-%d'") { script ->
- return [stdout: "2023-10-24", exitValue: 0]
- }
- helper.addShMock('env PATH=$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component k-NN --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar ', '', 1)
- assertThrows(Exception) {
- runScript('jenkins/opensearch/integ-test.jenkinsfile')
- }
- assertJobStatusFailure()
- assertThat(getCommandExecutions('println', 'Issue'), hasItem('Issue already exists, adding a comment'))
- assertThat(getCommandExecutions('sh', 'script'), hasItem("{script=gh issue list --repo https://github.com/opensearch-project/k-NN.git -S \"[AUTOCUT] Integration Test failed for k-NN: 3.0.0 in:title\" --json number --jq '.[0].number', returnStdout=true}"))
- assertThat(getCommandExecutions('sh', 'script'), hasItem("{script=gh issue comment bbb\nccc --repo https://github.com/opensearch-project/k-NN.git --body \"The integration test failed at distribution level for component k-NN
Version: 3.0.0
Distribution: tar
Architecture: x64
Platform: linux
Please check the logs: https://some/url/redirect
* Test-report manifest:*
- https://ci.opensearch.org/ci/dbc/dummy_job/3.0.0/9010/linux/x64/tar/test-results/234/integ-test/test-report.yml
_Note: Steps to reproduce, additional logs and other files can be found within the above test-report manifest.
Instructions of this test-report manifest can be found [here](https://github.com/opensearch-project/opensearch-build/tree/main/src/report_workflow#guide-on-test-report-manifest-from-ci)._\", returnStdout=true}"))
- }
-
- @Test
- void checkGHIssueDisable() {
- addParam('COMPONENT_NAME', 'k-NN')
- helper.addShMock("""env PATH=\$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component k-NN --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar """) { script ->
- return [stdout: "Error running integtest for component k-NN, creating Github issue", exitValue: 1]}
- assertThrows(Exception) {
- runScript('jenkins/opensearch/integ-test.jenkinsfile')
- }
- assertJobStatusFailure()
- assertThat(getCommandExecutions('sh', 'gh issue').size(), equalTo(0))
- }
-
- @Test
- void verifyLabelRemoval() {
- addParam('UPDATE_GITHUB_ISSUES', true)
- helper.addShMock("""gh issue list --repo https://github.com/opensearch-project/k-NN.git -S "[AUTOCUT] Integration Test failed for k-NN: 3.0.0 in:title" --json number --jq '.[0].number'""") { script ->
- return [stdout: "67", exitValue: 0]
- }
- helper.addShMock("""gh label list --repo https://github.com/opensearch-project/k-NN.git -S linux:tar:x64 --json name --jq '.[0].name'""") { script ->
- return [stdout: "linux:tar:x64", exitValue: 0]
- }
- helper.addShMock("""env PATH=\$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component k-NN --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/8184/linux/x64/tar""") { script ->
- return [stdout: "Completed running integtest for component k-NN", exitValue: 0]
- }
- runScript('jenkins/opensearch/integ-test.jenkinsfile')
- assertThat(getCommandExecutions('sh', 'gh issue'), hasItem('{script=gh issue edit 67 -R https://github.com/opensearch-project/k-NN.git --remove-label \"linux:tar:x64\", returnStdout=true}'))
- }
-
- @Test
- void verifyLabelAddition() {
- addParam('UPDATE_GITHUB_ISSUES', true)
- helper.addShMock("""env PATH=\$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component k-NN --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar """) { script ->
- return [stdout: "Error running integtest for component k-NN, creating Github issue", exitValue: 1]}
- helper.addShMock("""gh issue list --repo https://github.com/opensearch-project/k-NN.git -S "[AUTOCUT] Integration Test failed for k-NN: 3.0.0 in:title" --json number --jq '.[0].number'""") { script ->
- return [stdout: "99", exitValue: 0]
- }
- helper.addShMock("""gh label list --repo https://github.com/opensearch-project/k-NN.git -S linux:tar:x64 --json name --jq '.[0].name'""") { script ->
- return [stdout: "no labels in opensearch-project/k-NN matched your search", exitValue: 0]
- }
- assertThrows(Exception) {
- runScript('jenkins/opensearch/integ-test.jenkinsfile')
- }
- assertJobStatusFailure()
- assertThat(getCommandExecutions('sh', 'label'), hasItem("{script=gh label create linux:tar:x64 --repo https://github.com/opensearch-project/k-NN.git, returnStdout=true}"))
- assertThat(getCommandExecutions('sh', 'gh issue'), hasItem('{script=gh issue edit 99 -R https://github.com/opensearch-project/k-NN.git --add-label \"linux:tar:x64\", returnStdout=true}'))
- }
-
@Test
void whenValidationIsNotChecked() {
addParam('VALIDATE_ARTIFACTS', false)
diff --git a/tests/jenkins/jenkinsjob-regression-files/opensearch-dashboards/integ-test-without-validation.jenkinsfile.txt b/tests/jenkins/jenkinsjob-regression-files/opensearch-dashboards/integ-test-without-validation.jenkinsfile.txt
index da75b825b1..abeeb3c68f 100644
--- a/tests/jenkins/jenkinsjob-regression-files/opensearch-dashboards/integ-test-without-validation.jenkinsfile.txt
+++ b/tests/jenkins/jenkinsjob-regression-files/opensearch-dashboards/integ-test-without-validation.jenkinsfile.txt
@@ -472,21 +472,5 @@
postCleanup.cleanWs({disableDeferredWipeout=true, deleteDirs=true})
integ-test.node(Jenkins-Agent-AL2-X64-C54xlarge-Docker-Host, groovy.lang.Closure)
integ-test.script(groovy.lang.Closure)
- Messages.asBoolean()
- Messages.get([integ-test])
- integ-test.unstash({name=messages-integ-test})
- integ-test.findFiles({excludes=, glob=messages/*})
- integ-test.dir(messages, groovy.lang.Closure)
- integ-test.deleteDir()
- integ-test.publishNotification({icon=:white_check_mark:, message=Integration Tests Successful, extra=, credentialsId=jenkins-integ-test-webhook, manifest=tests/jenkins/data/opensearch-dashboards-3.0.0-test.yml})
- publishNotification.string({credentialsId=jenkins-integ-test-webhook, variable=WEBHOOK_URL})
- publishNotification.withCredentials([WEBHOOK_URL], groovy.lang.Closure)
- publishNotification.sh(curl -XPOST --header "Content-Type: application/json" --data '{"result_text":":white_check_mark:
-JOB_NAME=dummy_job
-BUILD_NUMBER=[215]
-MESSAGE=Integration Tests Successful
-BUILD_URL: htth://BUILD_URL_dummy.com
-MANIFEST: tests/jenkins/data/opensearch-dashboards-3.0.0-test.yml
-"}' "WEBHOOK_URL")
integ-test.postCleanup()
postCleanup.cleanWs({disableDeferredWipeout=true, deleteDirs=true})
diff --git a/tests/jenkins/jenkinsjob-regression-files/opensearch-dashboards/integ-test.jenkinsfile.txt b/tests/jenkins/jenkinsjob-regression-files/opensearch-dashboards/integ-test.jenkinsfile.txt
index fea2f04e2c..dbbccbd13b 100644
--- a/tests/jenkins/jenkinsjob-regression-files/opensearch-dashboards/integ-test.jenkinsfile.txt
+++ b/tests/jenkins/jenkinsjob-regression-files/opensearch-dashboards/integ-test.jenkinsfile.txt
@@ -484,21 +484,5 @@
postCleanup.cleanWs({disableDeferredWipeout=true, deleteDirs=true})
integ-test.node(Jenkins-Agent-AL2-X64-C54xlarge-Docker-Host, groovy.lang.Closure)
integ-test.script(groovy.lang.Closure)
- Messages.asBoolean()
- Messages.get([integ-test])
- integ-test.unstash({name=messages-integ-test})
- integ-test.findFiles({excludes=, glob=messages/*})
- integ-test.dir(messages, groovy.lang.Closure)
- integ-test.deleteDir()
- integ-test.publishNotification({icon=:white_check_mark:, message=Integration Tests Successful, extra=, credentialsId=jenkins-integ-test-webhook, manifest=tests/jenkins/data/opensearch-dashboards-3.0.0-test.yml})
- publishNotification.string({credentialsId=jenkins-integ-test-webhook, variable=WEBHOOK_URL})
- publishNotification.withCredentials([WEBHOOK_URL], groovy.lang.Closure)
- publishNotification.sh(curl -XPOST --header "Content-Type: application/json" --data '{"result_text":":white_check_mark:
-JOB_NAME=dummy_job
-BUILD_NUMBER=[215]
-MESSAGE=Integration Tests Successful
-BUILD_URL: htth://BUILD_URL_dummy.com
-MANIFEST: tests/jenkins/data/opensearch-dashboards-3.0.0-test.yml
-"}' "WEBHOOK_URL")
integ-test.postCleanup()
postCleanup.cleanWs({disableDeferredWipeout=true, deleteDirs=true})
diff --git a/tests/jenkins/jenkinsjob-regression-files/opensearch/integ-test-without-validation.jenkinsfile.txt b/tests/jenkins/jenkinsjob-regression-files/opensearch/integ-test-without-validation.jenkinsfile.txt
index c80e54d2df..424b78f95c 100644
--- a/tests/jenkins/jenkinsjob-regression-files/opensearch/integ-test-without-validation.jenkinsfile.txt
+++ b/tests/jenkins/jenkinsjob-regression-files/opensearch/integ-test-without-validation.jenkinsfile.txt
@@ -498,21 +498,5 @@
postCleanup.cleanWs({disableDeferredWipeout=true, deleteDirs=true})
integ-test.node(Jenkins-Agent-AL2-X64-C54xlarge-Docker-Host, groovy.lang.Closure)
integ-test.script(groovy.lang.Closure)
- Messages.asBoolean()
- Messages.get([integ-test])
- integ-test.unstash({name=messages-integ-test})
- integ-test.findFiles({excludes=, glob=messages/*})
- integ-test.dir(messages, groovy.lang.Closure)
- integ-test.deleteDir()
- integ-test.publishNotification({icon=:white_check_mark:, message=Integration Tests Successful, extra=, credentialsId=jenkins-integ-test-webhook, manifest=tests/jenkins/data/opensearch-3.0.0-test.yml})
- publishNotification.string({credentialsId=jenkins-integ-test-webhook, variable=WEBHOOK_URL})
- publishNotification.withCredentials([WEBHOOK_URL], groovy.lang.Closure)
- publishNotification.sh(curl -XPOST --header "Content-Type: application/json" --data '{"result_text":":white_check_mark:
-JOB_NAME=dummy_job
-BUILD_NUMBER=[234]
-MESSAGE=Integration Tests Successful
-BUILD_URL: htth://BUILD_URL_dummy.com
-MANIFEST: tests/jenkins/data/opensearch-3.0.0-test.yml
-"}' "WEBHOOK_URL")
integ-test.postCleanup()
postCleanup.cleanWs({disableDeferredWipeout=true, deleteDirs=true})
diff --git a/tests/jenkins/jenkinsjob-regression-files/opensearch/integ-test.jenkinsfile.txt b/tests/jenkins/jenkinsjob-regression-files/opensearch/integ-test.jenkinsfile.txt
index 57ba75cbd4..39d9c7e92a 100644
--- a/tests/jenkins/jenkinsjob-regression-files/opensearch/integ-test.jenkinsfile.txt
+++ b/tests/jenkins/jenkinsjob-regression-files/opensearch/integ-test.jenkinsfile.txt
@@ -115,13 +115,6 @@
runIntegTestScript.echo(Switch User to Non-Root (uid=1000): false)
runIntegTestScript.echo(Run command: env PATH=$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component ml-commons --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar )
runIntegTestScript.sh(env PATH=$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component ml-commons --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar )
- BuildManifest.getRepo(ml-commons)
- integ-test.updateGitHubIssueLabels({repoUrl=https://github.com/opensearch-project/ml-commons.git, issueTitle=[AUTOCUT] Integration Test failed for ml-commons: 3.0.0, label=linux:tar:x64, action=remove})
- updateGitHubIssueLabels.usernamePassword({credentialsId=jenkins-github-bot-token, passwordVariable=GITHUB_TOKEN, usernameVariable=GITHUB_USER})
- updateGitHubIssueLabels.withCredentials([[GITHUB_USER, GITHUB_TOKEN]], groovy.lang.Closure)
- updateGitHubIssueLabels.sh({script=gh issue list --repo https://github.com/opensearch-project/ml-commons.git -S "[AUTOCUT] Integration Test failed for ml-commons: 3.0.0 in:title" --json number --jq '.[0].number', returnStdout=true})
- updateGitHubIssueLabels.sh({script=gh label list --repo https://github.com/opensearch-project/ml-commons.git -S linux:tar:x64 --json name --jq '.[0].name', returnStdout=true})
- updateGitHubIssueLabels.println(linux:tar:x64 label does not exist. Skipping the label removal)
integ-test.echo(Completed running integtest for component ml-commons)
integ-test.uploadTestResults({buildManifestFileName=tests/jenkins/data/opensearch-3.0.0-build.yml, jobName=dummy_job})
uploadTestResults.legacySCM(groovy.lang.Closure)
@@ -176,13 +169,6 @@
runIntegTestScript.echo(Switch User to Non-Root (uid=1000): false)
runIntegTestScript.echo(Run command: env PATH=$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component anomaly-detection --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar )
runIntegTestScript.sh(env PATH=$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component anomaly-detection --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar )
- BuildManifest.getRepo(anomaly-detection)
- integ-test.updateGitHubIssueLabels({repoUrl=https://github.com/opensearch-project/anomaly-detection.git, issueTitle=[AUTOCUT] Integration Test failed for anomaly-detection: 3.0.0, label=linux:tar:x64, action=remove})
- updateGitHubIssueLabels.usernamePassword({credentialsId=jenkins-github-bot-token, passwordVariable=GITHUB_TOKEN, usernameVariable=GITHUB_USER})
- updateGitHubIssueLabels.withCredentials([[GITHUB_USER, GITHUB_TOKEN]], groovy.lang.Closure)
- updateGitHubIssueLabels.sh({script=gh issue list --repo https://github.com/opensearch-project/anomaly-detection.git -S "[AUTOCUT] Integration Test failed for anomaly-detection: 3.0.0 in:title" --json number --jq '.[0].number', returnStdout=true})
- updateGitHubIssueLabels.sh({script=gh label list --repo https://github.com/opensearch-project/anomaly-detection.git -S linux:tar:x64 --json name --jq '.[0].name', returnStdout=true})
- updateGitHubIssueLabels.println(linux:tar:x64 label does not exist. Skipping the label removal)
integ-test.echo(Completed running integtest for component anomaly-detection)
integ-test.uploadTestResults({buildManifestFileName=tests/jenkins/data/opensearch-3.0.0-build.yml, jobName=dummy_job})
uploadTestResults.legacySCM(groovy.lang.Closure)
@@ -237,13 +223,6 @@
runIntegTestScript.echo(Switch User to Non-Root (uid=1000): false)
runIntegTestScript.echo(Run command: env PATH=$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component neural-search --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar )
runIntegTestScript.sh(env PATH=$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component neural-search --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar )
- BuildManifest.getRepo(neural-search)
- integ-test.updateGitHubIssueLabels({repoUrl=https://github.com/opensearch-project/neural-search.git, issueTitle=[AUTOCUT] Integration Test failed for neural-search: 3.0.0, label=linux:tar:x64, action=remove})
- updateGitHubIssueLabels.usernamePassword({credentialsId=jenkins-github-bot-token, passwordVariable=GITHUB_TOKEN, usernameVariable=GITHUB_USER})
- updateGitHubIssueLabels.withCredentials([[GITHUB_USER, GITHUB_TOKEN]], groovy.lang.Closure)
- updateGitHubIssueLabels.sh({script=gh issue list --repo https://github.com/opensearch-project/neural-search.git -S "[AUTOCUT] Integration Test failed for neural-search: 3.0.0 in:title" --json number --jq '.[0].number', returnStdout=true})
- updateGitHubIssueLabels.sh({script=gh label list --repo https://github.com/opensearch-project/neural-search.git -S linux:tar:x64 --json name --jq '.[0].name', returnStdout=true})
- updateGitHubIssueLabels.println(linux:tar:x64 label does not exist. Skipping the label removal)
integ-test.echo(Completed running integtest for component neural-search)
integ-test.uploadTestResults({buildManifestFileName=tests/jenkins/data/opensearch-3.0.0-build.yml, jobName=dummy_job})
uploadTestResults.legacySCM(groovy.lang.Closure)
@@ -298,13 +277,6 @@
runIntegTestScript.echo(Switch User to Non-Root (uid=1000): false)
runIntegTestScript.echo(Run command: env PATH=$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component security-analytics --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar )
runIntegTestScript.sh(env PATH=$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component security-analytics --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar )
- BuildManifest.getRepo(security-analytics)
- integ-test.updateGitHubIssueLabels({repoUrl=https://github.com/opensearch-project/security-analytics.git, issueTitle=[AUTOCUT] Integration Test failed for security-analytics: 3.0.0, label=linux:tar:x64, action=remove})
- updateGitHubIssueLabels.usernamePassword({credentialsId=jenkins-github-bot-token, passwordVariable=GITHUB_TOKEN, usernameVariable=GITHUB_USER})
- updateGitHubIssueLabels.withCredentials([[GITHUB_USER, GITHUB_TOKEN]], groovy.lang.Closure)
- updateGitHubIssueLabels.sh({script=gh issue list --repo https://github.com/opensearch-project/security-analytics.git -S "[AUTOCUT] Integration Test failed for security-analytics: 3.0.0 in:title" --json number --jq '.[0].number', returnStdout=true})
- updateGitHubIssueLabels.sh({script=gh label list --repo https://github.com/opensearch-project/security-analytics.git -S linux:tar:x64 --json name --jq '.[0].name', returnStdout=true})
- updateGitHubIssueLabels.println(linux:tar:x64 label does not exist. Skipping the label removal)
integ-test.echo(Completed running integtest for component security-analytics)
integ-test.uploadTestResults({buildManifestFileName=tests/jenkins/data/opensearch-3.0.0-build.yml, jobName=dummy_job})
uploadTestResults.legacySCM(groovy.lang.Closure)
@@ -359,13 +331,6 @@
runIntegTestScript.echo(Switch User to Non-Root (uid=1000): false)
runIntegTestScript.echo(Run command: env PATH=$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component security --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar )
runIntegTestScript.sh(env PATH=$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component security --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar )
- BuildManifest.getRepo(security)
- integ-test.updateGitHubIssueLabels({repoUrl=https://github.com/opensearch-project/security.git, issueTitle=[AUTOCUT] Integration Test failed for security: 3.0.0, label=linux:tar:x64, action=remove})
- updateGitHubIssueLabels.usernamePassword({credentialsId=jenkins-github-bot-token, passwordVariable=GITHUB_TOKEN, usernameVariable=GITHUB_USER})
- updateGitHubIssueLabels.withCredentials([[GITHUB_USER, GITHUB_TOKEN]], groovy.lang.Closure)
- updateGitHubIssueLabels.sh({script=gh issue list --repo https://github.com/opensearch-project/security.git -S "[AUTOCUT] Integration Test failed for security: 3.0.0 in:title" --json number --jq '.[0].number', returnStdout=true})
- updateGitHubIssueLabels.sh({script=gh label list --repo https://github.com/opensearch-project/security.git -S linux:tar:x64 --json name --jq '.[0].name', returnStdout=true})
- updateGitHubIssueLabels.println(linux:tar:x64 label does not exist. Skipping the label removal)
integ-test.echo(Completed running integtest for component security)
integ-test.uploadTestResults({buildManifestFileName=tests/jenkins/data/opensearch-3.0.0-build.yml, jobName=dummy_job})
uploadTestResults.legacySCM(groovy.lang.Closure)
@@ -420,13 +385,6 @@
runIntegTestScript.echo(Switch User to Non-Root (uid=1000): false)
runIntegTestScript.echo(Run command: env PATH=$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component k-NN --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar )
runIntegTestScript.sh(env PATH=$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component k-NN --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar )
- BuildManifest.getRepo(k-NN)
- integ-test.updateGitHubIssueLabels({repoUrl=https://github.com/opensearch-project/k-NN.git, issueTitle=[AUTOCUT] Integration Test failed for k-NN: 3.0.0, label=linux:tar:x64, action=remove})
- updateGitHubIssueLabels.usernamePassword({credentialsId=jenkins-github-bot-token, passwordVariable=GITHUB_TOKEN, usernameVariable=GITHUB_USER})
- updateGitHubIssueLabels.withCredentials([[GITHUB_USER, GITHUB_TOKEN]], groovy.lang.Closure)
- updateGitHubIssueLabels.sh({script=gh issue list --repo https://github.com/opensearch-project/k-NN.git -S "[AUTOCUT] Integration Test failed for k-NN: 3.0.0 in:title" --json number --jq '.[0].number', returnStdout=true})
- updateGitHubIssueLabels.sh({script=gh label list --repo https://github.com/opensearch-project/k-NN.git -S linux:tar:x64 --json name --jq '.[0].name', returnStdout=true})
- updateGitHubIssueLabels.println(linux:tar:x64 label does not exist. Skipping the label removal)
integ-test.echo(Completed running integtest for component k-NN)
integ-test.uploadTestResults({buildManifestFileName=tests/jenkins/data/opensearch-3.0.0-build.yml, jobName=dummy_job})
uploadTestResults.legacySCM(groovy.lang.Closure)
@@ -481,13 +439,6 @@
runIntegTestScript.echo(Switch User to Non-Root (uid=1000): false)
runIntegTestScript.echo(Run command: env PATH=$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component notifications --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar )
runIntegTestScript.sh(env PATH=$PATH JAVA_HOME=/opt/java/openjdk-17 ./test.sh integ-test manifests/tests/jenkins/data/opensearch-3.0.0-test.yml --component notifications --test-run-id 234 --paths opensearch=/tmp/workspace/tar --base-path DUMMY_PUBLIC_ARTIFACT_URL/dummy_job/3.0.0/9010/linux/x64/tar )
- BuildManifest.getRepo(notifications)
- integ-test.updateGitHubIssueLabels({repoUrl=https://github.com/opensearch-project/notifications.git, issueTitle=[AUTOCUT] Integration Test failed for notifications: 3.0.0, label=linux:tar:x64, action=remove})
- updateGitHubIssueLabels.usernamePassword({credentialsId=jenkins-github-bot-token, passwordVariable=GITHUB_TOKEN, usernameVariable=GITHUB_USER})
- updateGitHubIssueLabels.withCredentials([[GITHUB_USER, GITHUB_TOKEN]], groovy.lang.Closure)
- updateGitHubIssueLabels.sh({script=gh issue list --repo https://github.com/opensearch-project/notifications.git -S "[AUTOCUT] Integration Test failed for notifications: 3.0.0 in:title" --json number --jq '.[0].number', returnStdout=true})
- updateGitHubIssueLabels.sh({script=gh label list --repo https://github.com/opensearch-project/notifications.git -S linux:tar:x64 --json name --jq '.[0].name', returnStdout=true})
- updateGitHubIssueLabels.println(linux:tar:x64 label does not exist. Skipping the label removal)
integ-test.echo(Completed running integtest for component notifications)
integ-test.uploadTestResults({buildManifestFileName=tests/jenkins/data/opensearch-3.0.0-build.yml, jobName=dummy_job})
uploadTestResults.legacySCM(groovy.lang.Closure)
@@ -558,21 +509,5 @@
postCleanup.cleanWs({disableDeferredWipeout=true, deleteDirs=true})
integ-test.node(Jenkins-Agent-AL2-X64-C54xlarge-Docker-Host, groovy.lang.Closure)
integ-test.script(groovy.lang.Closure)
- Messages.asBoolean()
- Messages.get([integ-test])
- integ-test.unstash({name=messages-integ-test})
- integ-test.findFiles({excludes=, glob=messages/*})
- integ-test.dir(messages, groovy.lang.Closure)
- integ-test.deleteDir()
- integ-test.publishNotification({icon=:white_check_mark:, message=Integration Tests Successful, extra=, credentialsId=jenkins-integ-test-webhook, manifest=tests/jenkins/data/opensearch-3.0.0-test.yml})
- publishNotification.string({credentialsId=jenkins-integ-test-webhook, variable=WEBHOOK_URL})
- publishNotification.withCredentials([WEBHOOK_URL], groovy.lang.Closure)
- publishNotification.sh(curl -XPOST --header "Content-Type: application/json" --data '{"result_text":":white_check_mark:
-JOB_NAME=dummy_job
-BUILD_NUMBER=[234]
-MESSAGE=Integration Tests Successful
-BUILD_URL: htth://BUILD_URL_dummy.com
-MANIFEST: tests/jenkins/data/opensearch-3.0.0-test.yml
-"}' "WEBHOOK_URL")
integ-test.postCleanup()
postCleanup.cleanWs({disableDeferredWipeout=true, deleteDirs=true})