-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(EMS-3063): no PDF - Your business - Turnover - Dynamic legend (#…
…2467) * feat(EMS-3063): made turnover legend dynamic with currency * feat(EMS-3063): lint fix * feat(EMS-3063): lint fix * feat(EMS-3063): code and test improvements * feat(EMS-3063): lint fix * feat(EMS-3063): lint fix --------- Co-authored-by: Zain Kassam <zkassam@ukexportfinance.gov.uk>
- Loading branch information
Showing
15 changed files
with
192 additions
and
172 deletions.
There are no files selected for viewing
22 changes: 22 additions & 0 deletions
22
e2e-tests/commands/shared-commands/assertions/assert-copy-with-currency-name.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
/** | ||
* assertCopyWithCurrencyName | ||
* Assert a selector with a currency name and optional question mark | ||
* @param {String} pageTitle: Page title | ||
* @param {String} currencyName: Currency name | ||
* @param {String} currencyName: Currency name | ||
* @param {Function} selector: Cypress selector | ||
* @param {Boolean} withQuestionMark: Add a question mark to the expected text. | ||
*/ | ||
const assertCopyWithCurrencyName = ({ | ||
pageTitle, currencyName, selector, withQuestionMark = false, | ||
}) => { | ||
let expected = `${pageTitle} ${currencyName}`; | ||
|
||
if (withQuestionMark) { | ||
expected += '?'; | ||
} | ||
|
||
cy.checkText(selector, expected); | ||
}; | ||
|
||
export default assertCopyWithCurrencyName; |
24 changes: 0 additions & 24 deletions
24
e2e-tests/commands/shared-commands/assertions/assert-heading-with-currency-name.js
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.