saleor-dashboard/cypress/elements/catalog/giftCard/giftCardDialog.js
Karolina Rakoczy 35e48a635f
Add tests for gift cards (#1779)
* added tests for gift cards

* update tests names for gift cards

* change naming, move functions from test file, fix testId

* fix move function

* Edit test case name

Co-authored-by: Ewa Czerniak <ewa.czerniak@saleor.io>

Co-authored-by: Ewa Czerniak <ewa.czerniak@saleor.io>
2022-02-01 11:58:02 +01:00

18 lines
796 B
JavaScript

export const GIFT_CARD_DIALOG = {
amountInput: '[name="balanceAmount"]',
currencySelectButton: '[id="mui-component-select-balanceCurrency"]',
currenciesOptions: '[data-test="selectFieldOption"]',
expirationOptions: {
setExpiryDateCheckbox: '[name="expirySelected"]',
neverExpireRadioButton: '[value="NEVER_EXPIRE"]',
expiryPeriodRadioButton: '[value="EXPIRY_PERIOD"]',
expiryDateRadioButton: '[value="EXPIRY_DATE"]',
expiryPeriodAmount: '[name="expiryPeriodAmount"]',
expiryPeriodTypeButton: '[id*="select-expiryPeriodType"]',
expiryPeriodMonthType: '[data-test-id="MONTH"]',
expiryDateInput: '[name="expiryDate"]'
},
noteInput: '[name="note"]',
cardCodeText: '[data-test-id="cardCode"]',
tagInput: '[data-test-id="gift-card-tag-select-field"]'
};