Whether can use Array variable "testingData" in cy.mount for Angular Component Testing? #24050
Unanswered
787681277
asked this question in
Component Testing
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
const testingData = [
{
text: 'aa-testingData',
title: 'Hong Kong-testingData',
expanded: false
},
{
text: 'bb-testingData',
title: 'Stockholm-testingData',
expanded: false
},
{
text: 'cc-testingData',
title: 'Hong Kong-testingData',
expanded: true
},
{
text: 'dd-testingData',
title: 'Hong Kong-testingData',
expanded: true
}
];
============================================
it('supports an "Input()" count that sets the value', () => {
// Arrange
cy.mount(
<app-stepper [count]=${testingData}></app-stepper>
, {declarations: [StepperComponent],
})
// Assert
cy.get(counterSelector).should('have.text', '100')
})
If "testingData" is a Array variable, do we support ?
Beta Was this translation helpful? Give feedback.
All reactions