Skip to content

Commit

Permalink
Merge branch 'development' into test
Browse files Browse the repository at this point in the history
  • Loading branch information
nikiwycherley committed Jun 14, 2022
2 parents d4cbe28 + 9c47976 commit 3c948c6
Show file tree
Hide file tree
Showing 9 changed files with 20 additions and 20 deletions.
2 changes: 1 addition & 1 deletion server/models/outlook.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ class Outlook {
}
})

this._full = outlook.public_forecast.english_forecast
this._full = outlook.public_forecast.england_forecast

const issueDate = new Date(outlook.issued_at)

Expand Down
4 changes: 2 additions & 2 deletions test/data/fgs.json
Original file line number Diff line number Diff line change
Expand Up @@ -2458,9 +2458,9 @@
],
"public_forecast":{
"id":1212,
"english_forecast":"Ongoing river flooding is expected in parts of South Yorkshire, Nottinghamshire, Derbyshire and Lincolnshire today (Saturday) as a result of rain that has already fallen. This is expected to continue through until Wednesday in South Yorkshire, and until Sunday in Nottinghamshire and Derbyshire. \n\nProperties will flood and there will be travel disruption. \n\nLocalised river and surface water flooding impacts are probable on Saturday and Sunday in parts of central and southern England and are possible more widely in parts of England and Wales. Localised river and surface water flooding impacts are also possible across parts of the southern Pennines and are possible but not expected more widely across parts of England and Wales on Monday, Tuesday and Wednesday. \n\nLand, roads and some properties may flood and there may be travel disruption.",
"england_forecast":"Ongoing river flooding is expected in parts of South Yorkshire, Nottinghamshire, Derbyshire and Lincolnshire today (Saturday) as a result of rain that has already fallen. This is expected to continue through until Wednesday in South Yorkshire, and until Sunday in Nottinghamshire and Derbyshire. \n\nProperties will flood and there will be travel disruption. \n\nLocalised river and surface water flooding impacts are probable on Saturday and Sunday in parts of central and southern England and are possible more widely in parts of England and Wales. Localised river and surface water flooding impacts are also possible across parts of the southern Pennines and are possible but not expected more widely across parts of England and Wales on Monday, Tuesday and Wednesday. \n\nLand, roads and some properties may flood and there may be travel disruption.",
"welsh_forecast":"Mae disgwyl llifogydd parhaus mewn afonydd mewn rhannau o Dde Sir Efrog, Sir Nottingham, Sir Derby a Sir Lincoln heddiw (dydd Sadwrn) o ganlyniad i law sydd eisoes wedi cwympo. Disgwylir i hyn barhau drwodd tan ddydd Mercher yn Ne Sir Efrog, a tan ddydd Sul yn Sir Nottingham a Sir Derby.\nBydd eiddo'n gorlifo a bydd aflonyddwch teithio.\nMae effeithiau llifogydd dŵr afon a dŵr lleol yn debygol ddydd Sadwrn a dydd Sul mewn rhannau o ganol a de Lloegr ac maent yn bosibl yn ehangach mewn rhannau o Gymru a Lloegr.\nMae effeithiau llifogydd dŵr afon a dŵr lleol hefyd yn bosibl ar draws rhannau o dde'r Pennines ac maent yn bosibl ond ni ddisgwylir yn ehangach ar draws rhannau o Gymru a Lloegr ddydd Llun, Mawrth a Mercher.\nGall tir, ffyrdd a rhai eiddo orlifo ac efallai y bydd aflonyddwch teithio.",
"england_forecast":"Service not available.",
"english_forecast":"Service not available.",
"wales_forecast_english":"Service not available.",
"wales_forecast_welsh":"Service not available.",
"published_at":"2019-11-09T15:33:15Z"
Expand Down
4 changes: 2 additions & 2 deletions test/data/fgsCoastal.json
Original file line number Diff line number Diff line change
Expand Up @@ -20132,9 +20132,9 @@
],
"public_forecast": {
"id": 1162,
"english_forecast": "Coastal/tidal flooding is probable for many parts of the English and Welsh coastline today (Monday) and Tuesday, continuing for the east coast of England on Wednesday. This is due to high tides and strong winds at times. \n\nRiver and surface water flooding is expected this afternoon and tonight for mainly central parts of England and also Wales, due to further heavy rain. On Tuesday, local flooding from surface water and small rivers is also possible, mainly for the southern half of England and Wales due to heavy showers.\n\nOn Friday, for the south-west of England and Wales, coastal, river and surface water flooding are currently possible but not expected.\n\nLand, roads and some properties could flood and there will likely be travel disruption in places. ",
"england_forecast": "Coastal/tidal flooding is probable for many parts of the English and Welsh coastline today (Monday) and Tuesday, continuing for the east coast of England on Wednesday. This is due to high tides and strong winds at times. \n\nRiver and surface water flooding is expected this afternoon and tonight for mainly central parts of England and also Wales, due to further heavy rain. On Tuesday, local flooding from surface water and small rivers is also possible, mainly for the southern half of England and Wales due to heavy showers.\n\nOn Friday, for the south-west of England and Wales, coastal, river and surface water flooding are currently possible but not expected.\n\nLand, roads and some properties could flood and there will likely be travel disruption in places. ",
"welsh_forecast": "Mae llifogydd arfordirol/llanw yn debygol ar gyfer sawl rhan o arfordir Cymru a Lloegr heddiw (Dydd Llun) a Dydd Mawrth, gan barhau ar gyfer arfordir dwyreiniol Lloegr ddydd Mercher. Mae hyn oherwydd llanwau uchel a gwyntoedd cryf ar brydiau. \n\nDisgwylir llifogydd afonydd a dŵr wyneb y prynhawn yma a heno ar draws rhannau canolog o Loegr yn bennaf a Chymru hefyd, oherwydd glaw trwm pellach. Ar ddydd Mawrth, mae llifogydd lleol o ddŵr wyneb ac afonydd bach hefyd yn bosibl, yn bennaf ar gyfer hanner deheuol Cymru a Lloegr oherwydd cawodydd trwm.\n\nAr ddydd Gwener, ar hyd De-orllewin Lloegr a Chymru, mae llifogydd arfordirol, afonydd a dŵr wyneb yn bosibl ar hyn o bryd ond ni ddisgwylir hynny.\n\nGallai tir, ffyrdd a rhai eiddo orlifo ac ac efallai y bydd aflonyddwch teithio.\n",
"england_forecast": "Service not available.",
"english_forecast": "Service not available.",
"wales_forecast_english": "Service not available.",
"wales_forecast_welsh": "Service not available.",
"published_at": "2019-09-30T10:57:37Z"
Expand Down
4 changes: 2 additions & 2 deletions test/data/fgsTrends.json
Original file line number Diff line number Diff line change
Expand Up @@ -20150,9 +20150,9 @@
],
"public_forecast":{
"id":1162,
"english_forecast":"Coastal/tidal flooding is probable for many parts of the English and Welsh coastline today (Monday) and Tuesday, continuing for the east coast of England on Wednesday. This is due to high tides and strong winds at times. \n\nRiver and surface water flooding is expected this afternoon and tonight for mainly central parts of England and also Wales, due to further heavy rain. On Tuesday, local flooding from surface water and small rivers is also possible, mainly for the southern half of England and Wales due to heavy showers.\n\nOn Friday, for the south-west of England and Wales, coastal, river and surface water flooding are currently possible but not expected.\n\nLand, roads and some properties could flood and there will likely be travel disruption in places. ",
"england_forecast":"Coastal/tidal flooding is probable for many parts of the English and Welsh coastline today (Monday) and Tuesday, continuing for the east coast of England on Wednesday. This is due to high tides and strong winds at times. \n\nRiver and surface water flooding is expected this afternoon and tonight for mainly central parts of England and also Wales, due to further heavy rain. On Tuesday, local flooding from surface water and small rivers is also possible, mainly for the southern half of England and Wales due to heavy showers.\n\nOn Friday, for the south-west of England and Wales, coastal, river and surface water flooding are currently possible but not expected.\n\nLand, roads and some properties could flood and there will likely be travel disruption in places. ",
"welsh_forecast":"Mae llifogydd arfordirol/llanw yn debygol ar gyfer sawl rhan o arfordir Cymru a Lloegr heddiw (Dydd Llun) a Dydd Mawrth, gan barhau ar gyfer arfordir dwyreiniol Lloegr ddydd Mercher. Mae hyn oherwydd llanwau uchel a gwyntoedd cryf ar brydiau. \n\nDisgwylir llifogydd afonydd a dŵr wyneb y prynhawn yma a heno ar draws rhannau canolog o Loegr yn bennaf a Chymru hefyd, oherwydd glaw trwm pellach. Ar ddydd Mawrth, mae llifogydd lleol o ddŵr wyneb ac afonydd bach hefyd yn bosibl, yn bennaf ar gyfer hanner deheuol Cymru a Lloegr oherwydd cawodydd trwm.\n\nAr ddydd Gwener, ar hyd De-orllewin Lloegr a Chymru, mae llifogydd arfordirol, afonydd a dŵr wyneb yn bosibl ar hyn o bryd ond ni ddisgwylir hynny.\n\nGallai tir, ffyrdd a rhai eiddo orlifo ac ac efallai y bydd aflonyddwch teithio.\n",
"england_forecast":"Service not available.",
"english_forecast":"Service not available.",
"wales_forecast_english":"Service not available.",
"wales_forecast_welsh":"Service not available.",
"published_at":"2019-09-30T10:57:37Z"
Expand Down
2 changes: 1 addition & 1 deletion test/data/outlook.json

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions test/models/outlook-tabs.js
Original file line number Diff line number Diff line change
Expand Up @@ -242,9 +242,9 @@ lab.experiment('outlookTabs model test', () => {
public_forecast:
{
id: 1107,
english_forecast: 'Local flooding from surface water and rivers is possible but not expected in places across much of the north of England on Friday due to widespread rain and heavy showers. Local flooding from rivers is possible, and flooding from surface water possible but not expected, across Wales and much of central and southern England on Friday.\nFurther local flooding from surface water and rivers is possible but not expected on Saturday and Sunday in parts of northern England due to heavy, thundery showers.\nLocal minor river and surface water flooding impacts are possible but not expected in parts of the north of England on Monday.\n\nProperties may flood and there may be travel disruption.',
england_forecast: 'Local flooding from surface water and rivers is possible but not expected in places across much of the north of England on Friday due to widespread rain and heavy showers. Local flooding from rivers is possible, and flooding from surface water possible but not expected, across Wales and much of central and southern England on Friday.\nFurther local flooding from surface water and rivers is possible but not expected on Saturday and Sunday in parts of northern England due to heavy, thundery showers.\nLocal minor river and surface water flooding impacts are possible but not expected in parts of the north of England on Monday.\n\nProperties may flood and there may be travel disruption.',
welsh_forecast: 'Mae llifogydd lleol o ddŵr wyneb ac afonydd yn bosibl ond nid yn ddisgwyliedig mewn mannau ar draws rhan fwyaf o ogledd Lloegr ar ddydd Gwener, o ganlyniad i law eang a chawodydd trwm. Mae llifogydd lleol o afonydd yn bosibl, a llifogydd o ddŵr wyneb yn bosibl ond heb eu disgwyl, ar draws Cymru a llawer o Ganolbarth a De Lloegr ar ddydd Gwener.\n\nMae\'n bosibl bydd llifogydd lleol pellach o ddŵr wyneb ac afonydd, ond heb eu disgwyl, ar ddydd Sadwrn a dydd Sul mewn rhannau o ogledd Lloegr oherwydd cawodydd trwm a stormydd. \n\nBydd siawns o effaith lifogydd o afonydd a dwr wyneb lleol mewn rhannau o Ogledd Lloegr ar Ddydd Llun ond nid yw hyn yn ddisgwyliedig. \n\nGall eiddo orlifo ac mae \'n bosibl y bydd tarfu ar deithio.\n',
england_forecast: 'Service not available.',
english_forecast: 'Service not available.',
wales_forecast_english: 'Service not available.',
wales_forecast_welsh: 'Service not available.',
published_at: '2019-08-08T11:06:48Z'
Expand Down
12 changes: 6 additions & 6 deletions test/models/outlook.js
Original file line number Diff line number Diff line change
Expand Up @@ -98,9 +98,9 @@ lab.experiment('Outlook model test', () => {
public_forecast:
{
id: 1107,
english_forecast: 'Local flooding from surface water and rivers is possible but not expected in places across much of the north of England on Friday due to widespread rain and heavy showers. Local flooding from rivers is possible, and flooding from surface water possible but not expected, across Wales and much of central and southern England on Friday.\nFurther local flooding from surface water and rivers is possible but not expected on Saturday and Sunday in parts of northern England due to heavy, thundery showers.\nLocal minor river and surface water flooding impacts are possible but not expected in parts of the north of England on Monday.\n\nProperties may flood and there may be travel disruption.',
england_forecast: 'Local flooding from surface water and rivers is possible but not expected in places across much of the north of England on Friday due to widespread rain and heavy showers. Local flooding from rivers is possible, and flooding from surface water possible but not expected, across Wales and much of central and southern England on Friday.\nFurther local flooding from surface water and rivers is possible but not expected on Saturday and Sunday in parts of northern England due to heavy, thundery showers.\nLocal minor river and surface water flooding impacts are possible but not expected in parts of the north of England on Monday.\n\nProperties may flood and there may be travel disruption.',
welsh_forecast: 'Mae llifogydd lleol o ddŵr wyneb ac afonydd yn bosibl ond nid yn ddisgwyliedig mewn mannau ar draws rhan fwyaf o ogledd Lloegr ar ddydd Gwener, o ganlyniad i law eang a chawodydd trwm. Mae llifogydd lleol o afonydd yn bosibl, a llifogydd o ddŵr wyneb yn bosibl ond heb eu disgwyl, ar draws Cymru a llawer o Ganolbarth a De Lloegr ar ddydd Gwener.\n\nMae\'n bosibl bydd llifogydd lleol pellach o ddŵr wyneb ac afonydd, ond heb eu disgwyl, ar ddydd Sadwrn a dydd Sul mewn rhannau o ogledd Lloegr oherwydd cawodydd trwm a stormydd. \n\nBydd siawns o effaith lifogydd o afonydd a dwr wyneb lleol mewn rhannau o Ogledd Lloegr ar Ddydd Llun ond nid yw hyn yn ddisgwyliedig. \n\nGall eiddo orlifo ac mae \'n bosibl y bydd tarfu ar deithio.\n',
england_forecast: 'Service not available.',
english_forecast: 'Service not available.',
wales_forecast_english: 'Service not available.',
wales_forecast_welsh: 'Service not available.',
published_at: '2019-08-08T11:06:48Z'
Expand Down Expand Up @@ -232,9 +232,9 @@ lab.experiment('Outlook model test', () => {
public_forecast:
{
id: 1107,
english_forecast: 'Local flooding from surface water and rivers is possible but not expected in places across much of the north of England on Friday due to widespread rain and heavy showers. Local flooding from rivers is possible, and flooding from surface water possible but not expected, across Wales and much of central and southern England on Friday.\nFurther local flooding from surface water and rivers is possible but not expected on Saturday and Sunday in parts of northern England due to heavy, thundery showers.\nLocal minor river and surface water flooding impacts are possible but not expected in parts of the north of England on Monday.\n\nProperties may flood and there may be travel disruption.',
england_forecast: 'Local flooding from surface water and rivers is possible but not expected in places across much of the north of England on Friday due to widespread rain and heavy showers. Local flooding from rivers is possible, and flooding from surface water possible but not expected, across Wales and much of central and southern England on Friday.\nFurther local flooding from surface water and rivers is possible but not expected on Saturday and Sunday in parts of northern England due to heavy, thundery showers.\nLocal minor river and surface water flooding impacts are possible but not expected in parts of the north of England on Monday.\n\nProperties may flood and there may be travel disruption.',
welsh_forecast: 'Mae llifogydd lleol o ddŵr wyneb ac afonydd yn bosibl ond nid yn ddisgwyliedig mewn mannau ar draws rhan fwyaf o ogledd Lloegr ar ddydd Gwener, o ganlyniad i law eang a chawodydd trwm. Mae llifogydd lleol o afonydd yn bosibl, a llifogydd o ddŵr wyneb yn bosibl ond heb eu disgwyl, ar draws Cymru a llawer o Ganolbarth a De Lloegr ar ddydd Gwener.\n\nMae\'n bosibl bydd llifogydd lleol pellach o ddŵr wyneb ac afonydd, ond heb eu disgwyl, ar ddydd Sadwrn a dydd Sul mewn rhannau o ogledd Lloegr oherwydd cawodydd trwm a stormydd. \n\nBydd siawns o effaith lifogydd o afonydd a dwr wyneb lleol mewn rhannau o Ogledd Lloegr ar Ddydd Llun ond nid yw hyn yn ddisgwyliedig. \n\nGall eiddo orlifo ac mae \'n bosibl y bydd tarfu ar deithio.\n',
england_forecast: 'Service not available.',
english_forecast: 'Service not available.',
wales_forecast_english: 'Service not available.',
wales_forecast_welsh: 'Service not available.',
published_at: '2019-08-08T11:06:48Z'
Expand Down Expand Up @@ -329,9 +329,9 @@ lab.experiment('Outlook model test', () => {
}],
public_forecast: {
id: 1830,
english_forecast: 'Local flooding is possible from rivers in parts of the north of England.',
england_forecast: 'Local flooding is possible from rivers in parts of the north of England.',
welsh_forecast: 'Service unavailable.',
england_forecast: 'Service unavailable.',
english_forecast: 'Service unavailable.',
wales_forecast_english: 'Local coastal flooding is possible but not expected',
wales_forecast_welsh: 'Mae llifogydd arfordirol lleol yn bosibl ond ni ddisgwylir.',
published_at: '2021-03-29T10:14:23Z'
Expand Down
6 changes: 3 additions & 3 deletions test/routes/location.js
Original file line number Diff line number Diff line change
Expand Up @@ -1385,9 +1385,9 @@ lab.experiment('Routes test - location - 2', () => {
aoc_maps: [],
public_forecast: {
id: 1823,
english_forecast: 'The forecast flood risk across England and Wales for today and the next four days is very low.',
england_forecast: 'The forecast flood risk across England and Wales for today and the next four days is very low.',
welsh_forecast: 'Service unavailable',
england_forecast: 'Service unavailable',
english_forecast: 'Service unavailable',
wales_forecast_english: 'The forecast flood risk across Wales for today and the next four days is very low.',
wales_forecast_welsh: "Rhagwelir fod y perygl llifogydd ar draws Cymru ar gyfer heddiw a'r pedwar diwrnod nesaf yn isel iawn.",
published_at: '2021-03-22T10:06:15Z'
Expand Down Expand Up @@ -1707,7 +1707,7 @@ lab.experiment('Routes test - location - 2', () => {
],
headline: 'Minor river flooding is possible',
amendments: '',
public_forecast: { english_forecast: 'Good' },
public_forecast: { england_forecast: 'Good' },
future_forecast: '',
last_modified_at: '2021-03-29T09:18:29Z',
next_issue_due_at: '2021-03-30T09:30:00Z',
Expand Down
2 changes: 1 addition & 1 deletion test/routes/national.js
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,7 @@ lab.experiment('Routes test - national view', () => {
],
headline: 'Minor river flooding is possible',
amendments: '',
public_forecast: { english_forecast: 'Good' },
public_forecast: { england_forecast: 'Good' },
future_forecast: '',
last_modified_at: '2021-03-29T09:18:29Z',
next_issue_due_at: '2021-03-30T09:30:00Z',
Expand Down

0 comments on commit 3c948c6

Please sign in to comment.