test(client): match any dates (linkedin button) (#39754)

Co-authored-by: Twaha Rahman <39026437+Twaha-Rahman@users.noreply.github.com>
Co-authored-by: Tom <20648924+moT01@users.noreply.github.com>
This commit is contained in:
Oliver Eyton-Williams
2020-10-01 16:10:00 +02:00
committed by GitHub
parent 41d40608a1
commit 2b60d14b5c

View File

@ -52,11 +52,13 @@ describe('A certification,', function() {
}); });
it('should render a LinkedIn button', function() { it('should render a LinkedIn button', function() {
cy.contains('Add this certification to my LinkedIn profile').should( cy.contains('Add this certification to my LinkedIn profile')
'have.attr', .should('have.attr', 'href')
'href', .and(
'https://www.linkedin.com/profile/add?startTask=CERTIFICATION_NAME&name=Legacy Front End&organizationId=4831032&issueYear=2020&issueMonth=8&certUrl=https://freecodecamp.org/certification/developmentuser/legacy-front-end' 'match',
); // eslint-disable-next-line max-len
/https:\/\/www\.linkedin\.com\/profile\/add\?startTask=CERTIFICATION_NAME&name=Legacy Front End&organizationId=4831032&issueYear=\d\d\d\d&issueMonth=\d\d?&certUrl=https:\/\/freecodecamp\.org\/certification\/developmentuser\/legacy-front-end/
);
}); });
it('should render a Twitter button', function() { it('should render a Twitter button', function() {