Skip to content

Commit

Permalink
Merge pull request #12212 from bbc/WSTEAMA-1474-move-serbian-and-zhon…
Browse files Browse the repository at this point in the history
…gwen-to-migrated-services

WSTEAMA-1474 - Move Serbian and Zhongwen to list of migrated services
  • Loading branch information
holchris authored Dec 10, 2024
2 parents e015b58 + efcf37f commit 204e4cc
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 66 deletions.
2 changes: 2 additions & 0 deletions cypress/e2e/pages/homePage/urls.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,13 @@ const urls = [
service: 'serbian',
local: '/serbian/lat',
test: '/serbian/lat',
live: '/serbian/lat',
},
{
service: 'serbian',
local: '/serbian/cyr',
test: '/serbian/cyr',
live: '/serbian/cyr',
},
];

Expand Down
66 changes: 7 additions & 59 deletions cypress/support/config/settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -5485,21 +5485,8 @@ module.exports = () => ({
smoke: true,
},
frontPage: {
environments: {
live: {
paths: ['/serbian/cyr'],
enabled: true,
},
test: {
paths: ['/serbian/cyr'],
enabled: false,
},
local: {
paths: ['/serbian/cyr'],
enabled: false,
},
},
smoke: true,
environments: undefined,
smoke: false,
},
liveRadio: { environments: undefined, smoke: false },
onDemandAudio: { environments: undefined, smoke: false },
Expand Down Expand Up @@ -5655,20 +5642,7 @@ module.exports = () => ({
smoke: true,
},
frontPage: {
environments: {
live: {
paths: ['/serbian/lat'],
enabled: true,
},
test: {
paths: ['/serbian/lat'],
enabled: false,
},
local: {
paths: ['/serbian/lat'],
enabled: false,
},
},
environments: undefined,
smoke: true,
},
liveRadio: { environments: undefined, smoke: false },
Expand Down Expand Up @@ -8846,21 +8820,8 @@ module.exports = () => ({
smoke: true,
},
frontPage: {
environments: {
live: {
paths: ['/zhongwen/simp'],
enabled: false,
},
test: {
paths: ['/zhongwen/simp'],
enabled: false,
},
local: {
paths: ['/zhongwen/simp'],
enabled: false,
},
},
smoke: true,
environments: undefined,
smoke: false,
},
liveRadio: { environments: undefined, smoke: false },
onDemandAudio: {
Expand Down Expand Up @@ -9053,21 +9014,8 @@ module.exports = () => ({
smoke: true,
},
frontPage: {
environments: {
live: {
paths: ['/zhongwen/trad'],
enabled: false,
},
test: {
paths: ['/zhongwen/trad'],
enabled: false,
},
local: {
paths: ['/zhongwen/trad'],
enabled: false,
},
},
smoke: true,
environments: undefined,
smoke: false,
},
liveRadio: { environments: undefined, smoke: false },
onDemandAudio: {
Expand Down
6 changes: 1 addition & 5 deletions lighthouse/lighthouserc.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
const AUDIT_URLS = {
FRONT_PAGE: {
live: ['https://www.bbc.com/serbian/cyr'],
test: [],
},
FIX: {
live: ['https://www.bbc.com/persian/science-52004647'],
test: [
Expand Down Expand Up @@ -57,7 +53,7 @@ const AUDIT_URLS = {
},

TIPO_HOME_PAGE: {
live: ['https://www.bbc.com/kyrgyz'],
live: ['https://www.bbc.com/kyrgyz', 'https://www.bbc.com/serbian/lat'],
test: [
'https://www.test.bbc.com/kyrgyz?renderer_env=live',
'https://www.test.bbc.com/serbian/lat?renderer_env=live',
Expand Down
2 changes: 2 additions & 0 deletions src/app/routes/utils/regex/index.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -531,6 +531,7 @@ describe('frontPage -> homePage migration', () => {
'portuguese',
'punjabi',
'russian',
'serbian',
'sinhala',
'somali',
'swahili',
Expand All @@ -543,6 +544,7 @@ describe('frontPage -> homePage migration', () => {
'urdu',
'vietnamese',
'yoruba',
'zhongwen',
];
const migratedWorldServiceRoutes = migratedServices.map(serviceToRoute);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@ exports[`regex utils snapshots should create expected regex from getErrorPageReg

exports[`regex utils snapshots should create expected regex from getFrontPageRegex when isLive = false 1`] = `"/:service():variant(/simp|/trad|/cyr|/lat)?:amp(.amp)?:lite(.lite)?"`;

exports[`regex utils snapshots should create expected regex from getFrontPageRegex when isLive = true 1`] = `"/:service(archive|cymrufyw|naidheachdan|news|newsround|scotland|serbian|sport|ukchina|uzbek|ws|zhongwen):variant(/simp|/trad|/cyr|/lat)?:amp(.amp)?:lite(.lite)?"`;
exports[`regex utils snapshots should create expected regex from getFrontPageRegex when isLive = true 1`] = `"/:service(archive|cymrufyw|naidheachdan|news|newsround|scotland|sport|ukchina|uzbek|ws):variant(/simp|/trad|/cyr|/lat)?:amp(.amp)?:lite(.lite)?"`;

exports[`regex utils snapshots should create expected regex from getHomePageRegex when isLive = false 1`] = `"/:service(afaanoromoo|afrique|amharic|arabic|archive|azeri|bengali|burmese|cymrufyw|gahuza|gujarati|hausa|hindi|igbo|indonesia|japanese|korean|kyrgyz|marathi|mundo|naidheachdan|nepali|news|newsround|pashto|persian|pidgin|portuguese|punjabi|russian|scotland|serbian|sinhala|somali|sport|swahili|tamil|telugu|thai|tigrinya|turkce|ukchina|ukrainian|urdu|uzbek|vietnamese|ws|yoruba|zhongwen):variant(/simp|/trad|/cyr|/lat)?:amp(.amp)?:lite(.lite)?"`;

exports[`regex utils snapshots should create expected regex from getHomePageRegex when isLive = true 1`] = `"/:service(afaanoromoo|afrique|amharic|arabic|azeri|bengali|burmese|gahuza|gujarati|hausa|hindi|igbo|indonesia|japanese|korean|kyrgyz|marathi|mundo|nepali|pashto|persian|pidgin|portuguese|punjabi|russian|sinhala|somali|swahili|tamil|telugu|thai|tigrinya|turkce|ukrainian|urdu|vietnamese|yoruba):variant(/simp|/trad|/cyr|/lat)?:amp(.amp)?:lite(.lite)?"`;
exports[`regex utils snapshots should create expected regex from getHomePageRegex when isLive = true 1`] = `"/:service(afaanoromoo|afrique|amharic|arabic|azeri|bengali|burmese|gahuza|gujarati|hausa|hindi|igbo|indonesia|japanese|korean|kyrgyz|marathi|mundo|nepali|pashto|persian|pidgin|portuguese|punjabi|russian|serbian|sinhala|somali|swahili|tamil|telugu|thai|tigrinya|turkce|ukrainian|urdu|vietnamese|yoruba|zhongwen):variant(/simp|/trad|/cyr|/lat)?:amp(.amp)?:lite(.lite)?"`;

exports[`regex utils snapshots should create expected regex from getLegacyAssetRegex when isLive = false 1`] = `"/:service(afaanoromoo|afrique|amharic|arabic|archive|azeri|bengali|burmese|cymrufyw|gahuza|gujarati|hausa|hindi|igbo|indonesia|japanese|korean|kyrgyz|marathi|mundo|naidheachdan|nepali|news|newsround|pashto|persian|pidgin|portuguese|punjabi|russian|scotland|serbian|sinhala|somali|sport|swahili|tamil|telugu|thai|tigrinya|turkce|ukchina|ukrainian|urdu|uzbek|vietnamese|ws|yoruba|zhongwen):variant(/simp|/trad|/cyr|/lat)?/:assetUri([a-z0-9-_]{1,}/[a-z0-9-_/]{1,}):amp(.amp)?:lite(.lite)?"`;

Expand Down
2 changes: 2 additions & 0 deletions src/app/routes/utils/regex/utils/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ const homePageServices = [
'portuguese',
'punjabi',
'russian',
'serbian',
'sinhala',
'somali',
'swahili',
Expand All @@ -72,6 +73,7 @@ const homePageServices = [
'urdu',
'vietnamese',
'yoruba',
'zhongwen',
];

export const getFrontPageRegex = services => {
Expand Down

0 comments on commit 204e4cc

Please sign in to comment.