Skip to content

Commit dea9ccd

Browse files
committed
test: add more scenarios to integration test
1 parent cb49b99 commit dea9ccd

File tree

5 files changed

+1117
-27
lines changed

5 files changed

+1117
-27
lines changed

src/components/KymaCompanion/components/Chat/TaskList/TasksList.cy.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ describe('TasksList Component', () => {
233233
);
234234
cy.get('.loading-item').should('have.css', 'align-items', 'center');
235235
cy.get('.text').should('exist');
236-
cy.get('.loading-status').should('exist');
236+
cy.get('.ai-steps-loader').should('exist');
237237
});
238238

239239
it('handles undefined tasks gracefully', () => {

src/components/KymaCompanion/components/Chat/TaskList/TasksList.scss

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,6 @@
1212
.text {
1313
flex-grow: 1;
1414
}
15-
16-
.loading-status {
17-
display: flex;
18-
align-items: center;
19-
justify-content: center;
20-
min-width: 35px;
21-
}
2215
}
2316
}
2417

src/components/KymaCompanion/components/Chat/TaskList/TasksList.tsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,6 @@ export default function TasksList({
4747
<span className="ai-steps-loader" />
4848
)}
4949
<Label className="text">{task?.task_name}</Label>
50-
<div className="loading-status" />
5150
</FlexBox>
5251
);
5352
},
@@ -62,7 +61,6 @@ export default function TasksList({
6261
<Label className="text">
6362
{t('kyma-companion.opener.preparing-final-answer')}
6463
</Label>
65-
<div className="loading-status" />
6664
</FlexBox>
6765
)}
6866
</>

tests/integration/support/navigate-to.js

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,10 @@ Cypress.Commands.add('navigateTo', (leftNav, resource) => {
44
.should('be.visible')
55
.click();
66

7-
cy.getLeftNav()
8-
.get(`ui5-side-navigation-sub-item[text="${resource}"]`)
9-
.should('be.visible')
10-
.click();
7+
if (resource) {
8+
cy.getLeftNav()
9+
.get(`ui5-side-navigation-sub-item[text="${resource}"]`)
10+
.should('be.visible')
11+
.click();
12+
}
1113
});

0 commit comments

Comments
 (0)