@defra-fish/gafl-webapp-service 1.60.0-rc.1 → 1.60.0-rc.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@defra-fish/gafl-webapp-service",
|
|
3
|
-
"version": "1.60.0-rc.
|
|
3
|
+
"version": "1.60.0-rc.3",
|
|
4
4
|
"description": "The websales frontend for the GAFL service",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"engines": {
|
|
@@ -36,8 +36,8 @@
|
|
|
36
36
|
"prepare": "gulp --gulpfile build/gulpfile.cjs"
|
|
37
37
|
},
|
|
38
38
|
"dependencies": {
|
|
39
|
-
"@defra-fish/business-rules-lib": "1.60.0-rc.
|
|
40
|
-
"@defra-fish/connectors-lib": "1.60.0-rc.
|
|
39
|
+
"@defra-fish/business-rules-lib": "1.60.0-rc.3",
|
|
40
|
+
"@defra-fish/connectors-lib": "1.60.0-rc.3",
|
|
41
41
|
"@defra/hapi-gapi": "^2.0.0",
|
|
42
42
|
"@hapi/boom": "^9.1.2",
|
|
43
43
|
"@hapi/catbox-redis": "^6.0.2",
|
|
@@ -80,5 +80,5 @@
|
|
|
80
80
|
"./gafl-jest-matchers.js"
|
|
81
81
|
]
|
|
82
82
|
},
|
|
83
|
-
"gitHead": "
|
|
83
|
+
"gitHead": "78528be2315fd176a037e49a3507587240deae93"
|
|
84
84
|
}
|
package/src/locales/cy.json
CHANGED
|
@@ -533,7 +533,7 @@
|
|
|
533
533
|
"new_prices_row_12_month": "12 mis",
|
|
534
534
|
"new_prices_row_concession": "12 mis - pobl hŷn neu anabl",
|
|
535
535
|
"new_prices_row_junior": "12 mis - ieuenctid (13 i 16)",
|
|
536
|
-
"newsletter_error_choose": "Dewiswch
|
|
536
|
+
"newsletter_error_choose": "Dewiswch un o’r opsiynau",
|
|
537
537
|
"newsletter_error_set_email": "Nodwch gyfeiriad e-bost yn y fformat cywir, fel enw@enghraifft.com",
|
|
538
538
|
"newsletter_subscribe": "Mynnwch yr wybodaeth ddiweddaraf am genweirio, pysgodfeydd a sut rydym yn gwario eich arian trwydded. Gallwch ddatdanysgrifio ar unrhyw adeg.",
|
|
539
539
|
"newsletter_title": "A hoffech chi dderbyn ein cylchlythyr dros e-bost?",
|
package/src/locales/en.json
CHANGED
|
@@ -533,7 +533,7 @@
|
|
|
533
533
|
"new_prices_row_12_month": "12-month",
|
|
534
534
|
"new_prices_row_concession": "12-month senior or disabled",
|
|
535
535
|
"new_prices_row_junior": "12-month junior (13 to 16)",
|
|
536
|
-
"newsletter_error_choose": "Choose
|
|
536
|
+
"newsletter_error_choose": "Choose one of the options",
|
|
537
537
|
"newsletter_error_set_email": "Enter an email address in the correct format, like name@example.com",
|
|
538
538
|
"newsletter_subscribe": "Stay up to date with the latest news on angling, fisheries and how we spend your licence money. You can unsubscribe at any time.",
|
|
539
539
|
"newsletter_title": "Would you like to receive our email newsletter?",
|
|
@@ -50,20 +50,15 @@ describe('validForRecurringPayment', () => {
|
|
|
50
50
|
|
|
51
51
|
describe('isRecurringPayment', () => {
|
|
52
52
|
it.each`
|
|
53
|
-
|
|
54
|
-
${
|
|
55
|
-
${
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
'recurringPayment returns $expected when SHOW_RECURRING_PAYMENTS is $show and the transaction agreementId is $agreementId',
|
|
60
|
-
async ({ show, agreementId, expected }) => {
|
|
61
|
-
process.env.SHOW_RECURRING_PAYMENTS = show
|
|
62
|
-
const transaction = { agreementId }
|
|
53
|
+
agreementId | expected
|
|
54
|
+
${'foo123'} | ${true}
|
|
55
|
+
${undefined} | ${false}
|
|
56
|
+
`('recurringPayment returns $expected when transaction agreementId is $agreementId', async ({ show, agreementId, expected }) => {
|
|
57
|
+
process.env.SHOW_RECURRING_PAYMENTS = show
|
|
58
|
+
const transaction = { agreementId }
|
|
63
59
|
|
|
64
|
-
|
|
60
|
+
expect(isRecurringPayment(transaction)).toBe(expected)
|
|
65
61
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
)
|
|
62
|
+
delete process.env.SHOW_RECURRING_PAYMENTS
|
|
63
|
+
})
|
|
69
64
|
})
|
|
@@ -22,4 +22,4 @@ export const validForRecurringPayment = permission => {
|
|
|
22
22
|
)
|
|
23
23
|
}
|
|
24
24
|
|
|
25
|
-
export const isRecurringPayment = transaction =>
|
|
25
|
+
export const isRecurringPayment = transaction => !!transaction.agreementId
|