From 3571dd1a7a0b603212a8b3cf2f9c8fe30eee9fe9 Mon Sep 17 00:00:00 2001 From: Alan Greene Date: Tue, 26 Sep 2023 18:08:21 +0100 Subject: [PATCH] Verify logs in Create TaskRun and Create PipelineRun E2E Ensure the log content is displayed correctly including the status footer when the step is complete. --- .../e2e/cypress/e2e/run/pipelinerun-create.cy.js | 12 ++++++++++++ packages/e2e/cypress/e2e/run/taskrun-create.cy.js | 12 ++++++++++++ 2 files changed, 24 insertions(+) diff --git a/packages/e2e/cypress/e2e/run/pipelinerun-create.cy.js b/packages/e2e/cypress/e2e/run/pipelinerun-create.cy.js index 8b0e529b9..02316c601 100644 --- a/packages/e2e/cypress/e2e/run/pipelinerun-create.cy.js +++ b/packages/e2e/cypress/e2e/run/pipelinerun-create.cy.js @@ -62,6 +62,9 @@ spec: cy.get('header[class="tkn--pipeline-run-header"]') .find('span[class="tkn--status-label"]', { timeout: 15000 }) .should('have.text', 'Succeeded'); + + cy.contains('.tkn--log', 'Hello World!'); + cy.contains('.tkn--log', 'Step completed successfully'); }); it('should populate YAML editor based on form inputs', function () { @@ -117,6 +120,9 @@ spec: cy.get('header[class="tkn--pipeline-run-header"]') .find('span[class="tkn--status-label"]', { timeout: 15000 }) .should('have.text', 'Succeeded'); + + cy.contains('.tkn--log', 'Hello World!'); + cy.contains('.tkn--log', 'Step completed successfully'); }); it('should create PipelineRun in YAML mode', function () { @@ -156,6 +162,9 @@ spec: cy.get('header[class="tkn--pipeline-run-header"]') .find('span[class="tkn--status-label"]', { timeout: 15000 }) .should('have.text', 'Succeeded'); + + cy.contains('.tkn--log', 'Hello World!'); + cy.contains('.tkn--log', 'Step completed successfully'); }); it('should create PipelineRun when open YAML mode directly', function () { @@ -192,5 +201,8 @@ spec: cy.get('header[class="tkn--pipeline-run-header"]') .find('span[class="tkn--status-label"]', { timeout: 15000 }) .should('have.text', 'Succeeded'); + + cy.contains('.tkn--log', 'Hello World!'); + cy.contains('.tkn--log', 'Step completed successfully'); }); }); diff --git a/packages/e2e/cypress/e2e/run/taskrun-create.cy.js b/packages/e2e/cypress/e2e/run/taskrun-create.cy.js index 2bdf1af35..3ef8ab3f7 100644 --- a/packages/e2e/cypress/e2e/run/taskrun-create.cy.js +++ b/packages/e2e/cypress/e2e/run/taskrun-create.cy.js @@ -57,6 +57,9 @@ spec: cy.get('header[class="tkn--pipeline-run-header"]') .find('span[class="tkn--status-label"]', { timeout: 15000 }) .should('have.text', 'Succeeded'); + + cy.contains('.tkn--log', 'Hello World!'); + cy.contains('.tkn--log', 'Step completed successfully'); }); it('should populate YAML editor based on form inputs', function () { @@ -107,6 +110,9 @@ spec: cy.get('header[class="tkn--pipeline-run-header"]') .find('span[class="tkn--status-label"]', { timeout: 15000 }) .should('have.text', 'Succeeded'); + + cy.contains('.tkn--log', 'Hello World!'); + cy.contains('.tkn--log', 'Step completed successfully'); }); it('should create TaskRun in YAML mode', function () { @@ -143,6 +149,9 @@ spec: cy.get('header[class="tkn--pipeline-run-header"]') .find('span[class="tkn--status-label"]', { timeout: 15000 }) .should('have.text', 'Succeeded'); + + cy.contains('.tkn--log', 'Hello World!'); + cy.contains('.tkn--log', 'Step completed successfully'); }); it('should create TaskRun when open YAML mode directly', function () { @@ -176,5 +185,8 @@ spec: cy.get('header[class="tkn--pipeline-run-header"]') .find('span[class="tkn--status-label"]', { timeout: 15000 }) .should('have.text', 'Succeeded'); + + cy.contains('.tkn--log', 'Hello World!'); + cy.contains('.tkn--log', 'Step completed successfully'); }); });