Skip to content

Commit

Permalink
remove import TC (#766)
Browse files Browse the repository at this point in the history
Signed-off-by: Alejandro Brugarolas <[email protected]>
  • Loading branch information
abrugaro authored Oct 25, 2023
1 parent 6866eb8 commit 5977f31
Showing 1 changed file with 3 additions and 53 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ describe(["@tier2"], "Application import operations", () => {
});

beforeEach("Persist session", function () {
// Interceptors
cy.intercept("GET", "/hub/application*").as("getApplication");
deleteAppImportsTableRows();
});
Expand All @@ -58,10 +57,8 @@ describe(["@tier2"], "Application import operations", () => {
exists("Inventory");
exists("Gateway");

// Open application imports page
openManageImportsPage();

// Verify import applications page shows correct information
verifyAppImport(fileName, "Completed", 5, 0);
});

Expand All @@ -74,15 +71,12 @@ describe(["@tier2"], "Application import operations", () => {
importApplication(filePath + fileName);
cy.wait(2000);

// Open application imports page
openManageImportsPage();

// Verify import applications page shows correct information
verifyAppImport(fileName, "Completed", 2, 3);

// Verify the error report messages
openErrorReport();
var errorMsgs = [
const errorMsgs = [
"UNIQUE constraint failed: Application.Name",
"UNIQUE constraint failed: Application.Name",
"UNIQUE constraint failed: Application.Name",
Expand All @@ -101,13 +95,10 @@ describe(["@tier2"], "Application import operations", () => {
importApplication(filePath + fileName, true);
cy.wait(2000);

// Open application imports page
openManageImportsPage();

// Verify import applications page shows correct information
verifyAppImport(fileName, "Completed", 0, 1);

// Verify the error report messages
openErrorReport();
verifyImportErrorMsg("Tag 'TypeScript' could not be found");

Expand All @@ -119,18 +110,15 @@ describe(["@tier2"], "Application import operations", () => {
Application.open();
cy.wait("@getApplication");

// Import csv with non-existent businsess service
// Import csv with non-existent business service
const fileName = "missing_business_21.csv";
importApplication(filePath + fileName, true);
cy.wait(2000);

// Open application imports page
openManageImportsPage();

// Verify import applications page shows correct information
verifyAppImport(fileName, "Completed", 0, 1);

// Verify the error report messages
openErrorReport();
verifyImportErrorMsg("BusinessService 'Finance' could not be found");
});
Expand All @@ -144,19 +132,10 @@ describe(["@tier2"], "Application import operations", () => {
importApplication(filePath + fileName);
cy.wait(2000);

/* // Verify imported apps are visible in table
exists("Import-app-5");
exists("Import-app-6");
// ToDO: need to modify exists method doesn't work here
*/

// Open application imports page
openManageImportsPage();

// Verify import applications page shows correct information
verifyAppImport(fileName, "Completed", 2, 1);

// Verify the error report message
openErrorReport();
verifyImportErrorMsg("Empty Record Type");
});
Expand All @@ -170,37 +149,14 @@ describe(["@tier2"], "Application import operations", () => {
importApplication(filePath + fileName);
cy.wait(2000);

// Open application imports page
openManageImportsPage();

// Verify import applications page shows correct information
verifyAppImport(fileName, "Completed", 1, 1);

// Verify the error report message
openErrorReport();
verifyImportErrorMsg("UNIQUE constraint failed: Application.Name");
});

it("Applications import having description and comments exceeding allowed limits", function () {
/*
// Unresolved 2.1 bug - https://issues.redhat.com/browse/TACKLE-738
selectUserPerspective("Developer");
clickByText(navMenu, applicationInventory);
cy.wait("@getApplication");
// Import csv having description and comments over the allowed limits
const fileName = "desc_comments_char_limit_rows.csv";
importApplication(filePath + fileName);
cy.wait(2000);
// Open application imports page
openManageImportsPage();
// Verify import applications page shows correct information
verifyAppImport(fileName, "Completed", 0, 2);
*/
});

it("Applications import for invalid csv schema", function () {
// Impacted by bug - https://issues.redhat.com/browse/TACKLE-320
Application.open();
Expand All @@ -211,15 +167,11 @@ describe(["@tier2"], "Application import operations", () => {
importApplication(filePath + fileName);
cy.wait(2000);

// Open application imports page
openManageImportsPage();

// Verify import applications page shows correct information
verifyAppImport(fileName, "Completed", 0, 2);

var errorMsgs = ["Invalid or unknown Record Type", "Invalid or unknown Record Type"];

// Verify the error report message
const errorMsgs = ["Invalid or unknown Record Type", "Invalid or unknown Record Type"];
openErrorReport();
verifyImportErrorMsg(errorMsgs);
});
Expand Down Expand Up @@ -267,8 +219,6 @@ describe(["@tier2"], "Application import operations", () => {
});

after("Perform test data clean up", function () {
// Business services and apps were created during app imports; Hence these functions are being used for
// cleanup.
deleteApplicationTableRows();
deleteAllBusinessServices();
});
Expand Down

0 comments on commit 5977f31

Please sign in to comment.