Skip to content

Commit

Permalink
test: fix e2e test
Browse files Browse the repository at this point in the history
  • Loading branch information
Mister-Hope committed Jan 31, 2024
1 parent 88deed1 commit c10cd88
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions e2e/tests/plugin-seo/seo.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,15 +57,16 @@ describe('seo', () => {
cy.get('head script[type="application/ld+json"]').then((el) => {
const json = JSON.parse(el[0].innerText)

expect(json).to.deep.equal({
'@context': 'https://schema.org',
'@type': 'Article',
'headline': 'SEO Demo Page',
'image': [`https://ecosystem-e2e-test.com${BASE}logo.png`],
'datePublished': '2021-01-01T00:00:00.000Z',
'dateModified': null,
'author': [{ '@type': 'Person', 'name': 'Mr.Hope' }],
})
expect(json['@context']).to.equal('https://schema.org')
expect(json['@type']).to.equal('Article')
expect(json.headline).to.equal('SEO Demo Page')
expect(json.image).to.deep.equal([
`https://ecosystem-e2e-test.com${BASE}logo.png`,
])
expect(json.datePublished).to.equal('2021-01-01T00:00:00.000Z')
expect(json).to.has.property('dateModified')
expect(json.author[0]['@type']).to.equal('Person')
expect(json.author[0].name).to.equal('Mr.Hope')
})
})
})

0 comments on commit c10cd88

Please sign in to comment.