Links and test changes

This commit is contained in:
apple502j 2019-11-19 01:34:19 +09:00
parent 3f61b09889
commit 6d9a7d20da
4 changed files with 9 additions and 11 deletions

View file

@ -22,7 +22,7 @@ const Footer = props => (
</a> </a>
</dd> </dd>
<dd> <dd>
<a href="/jobs"> <a href="https://www.scratchfoundation.org/opportunities">
<FormattedMessage id="general.jobs" /> <FormattedMessage id="general.jobs" />
</a> </a>
</dd> </dd>
@ -83,7 +83,7 @@ const Footer = props => (
</a> </a>
</dd> </dd>
<dd> <dd>
<a href="/jobs"> <a href="https://www.scratchfoundation.org/opportunities">
<FormattedMessage id="general.jobs" /> <FormattedMessage id="general.jobs" />
</a> </a>
</dd> </dd>

View file

@ -148,18 +148,16 @@
"title": "Ideas" "title": "Ideas"
}, },
{ {
"name": "jobs", "name": "jobs-redirect",
"pattern": "^/jobs/?$", "pattern": "^/jobs/?$",
"routeAlias": "/jobs(/moderator)?/?$", "routeAlias": "/jobs(/moderator)?/?$",
"view": "jobs/jobs", "redirect": "https://www.scratchfoundation.org/opportunities/"
"title": "Jobs"
}, },
{ {
"name": "jobs-moderator", "name": "jobs-redirect2",
"pattern": "^/jobs/moderator/?$", "pattern": "^/jobs/moderator/?$",
"routeAlias": "/jobs(/moderator)?/?$", "routeAlias": "/jobs(/moderator)?/?$",
"view": "jobs/moderator/moderator", "redirect": "https://www.scratchfoundation.org/opportunities/"
"title": "Community Moderator"
}, },
{ {
"name": "join", "name": "join",

View file

@ -228,7 +228,7 @@ const Developers = () => (
id="developers.joinBody" id="developers.joinBody"
values={{ values={{
jobsPageLink: ( jobsPageLink: (
<a href="/jobs"> <a href="https://www.scratchfoundation.org/opportunities">
<FormattedMessage id="developers.joinBodyJobsLinkText" /> <FormattedMessage id="developers.joinBodyJobsLinkText" />
</a> </a>
), ),

View file

@ -101,9 +101,9 @@ tap.test('clickCreditsLink', options, t => {
// JOBS // JOBS
tap.test('clickJobsLink', options, t => { tap.test('clickJobsLink', options, t => {
const linkText = 'Jobs'; const linkText = 'Jobs';
const expectedHref = '/jobs'; const expectedUrl = 'https://www.scratchfoundation.org/opportunities/';
clickFooterLinks(linkText).then(url => { clickFooterLinks(linkText).then(url => {
t.equal(url.substr(-expectedHref.length), expectedHref); t.equal(url, expectedUrl);
t.end(); t.end();
}); });
}); });