Skip to content

Commit

Permalink
Fix broken test
Browse files Browse the repository at this point in the history
  • Loading branch information
“kaganuk” committed Oct 28, 2022
1 parent ddff02c commit b149517
Show file tree
Hide file tree
Showing 46 changed files with 188 additions and 188 deletions.
8 changes: 4 additions & 4 deletions test/Controller/AboutAimsScopeControllerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -149,10 +149,10 @@ public function it_has_metadata()
$this->assertSame('eLife welcomes the submission of Research Articles, Short Reports, Tools and Resources articles, Research Advances, Scientific Correspondence and Review Articles in the subject areas below.', $crawler->filter('meta[property="og:description"]')->attr('content'));
$this->assertSame('eLife welcomes the submission of Research Articles, Short Reports, Tools and Resources articles, Research Advances, Scientific Correspondence and Review Articles in the subject areas below.', $crawler->filter('meta[name="description"]')->attr('content'));
$this->assertSame('summary', $crawler->filter('meta[name="twitter:card"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('280', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('200', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertEmpty($crawler->filter('meta[name="dc.identifier"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.relation.ispartof"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.title"]'));
Expand Down
8 changes: 4 additions & 4 deletions test/Controller/AboutControllerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ public function it_has_metadata()
$this->assertSame('Independent, not-for-profit and supported by funders, eLife improves the way research is practised and shared.', $crawler->filter('meta[property="og:description"]')->attr('content'));
$this->assertSame('Independent, not-for-profit and supported by funders, eLife improves the way research is practised and shared.', $crawler->filter('meta[name="description"]')->attr('content'));
$this->assertSame('summary', $crawler->filter('meta[name="twitter:card"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('280', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('200', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertEmpty($crawler->filter('meta[name="dc.identifier"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.relation.ispartof"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.title"]'));
Expand Down
8 changes: 4 additions & 4 deletions test/Controller/AboutPeerReviewControllerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ public function it_has_metadata()
$this->assertSame('eLife\'s review process combines the immediacy and openness of preprints with the scrutiny of peer review by experts.', $crawler->filter('meta[property="og:description"]')->attr('content'));
$this->assertSame('eLife\'s review process combines the immediacy and openness of preprints with the scrutiny of peer review by experts.', $crawler->filter('meta[name="description"]')->attr('content'));
$this->assertSame('summary', $crawler->filter('meta[name="twitter:card"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('280', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('200', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertEmpty($crawler->filter('meta[name="dc.identifier"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.relation.ispartof"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.title"]'));
Expand Down
8 changes: 4 additions & 4 deletions test/Controller/AboutPeopleControllerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -172,10 +172,10 @@ public function it_has_metadata()
$this->assertSame('eLife’s editors, early-career advisors, governing board, and executive staff work in concert to realise our mission.', $crawler->filter('meta[property="og:description"]')->attr('content'));
$this->assertSame('eLife’s editors, early-career advisors, governing board, and executive staff work in concert to realise our mission.', $crawler->filter('meta[name="description"]')->attr('content'));
$this->assertSame('summary', $crawler->filter('meta[name="twitter:card"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('280', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('200', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertEmpty($crawler->filter('meta[name="dc.identifier"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.relation.ispartof"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.title"]'));
Expand Down
8 changes: 4 additions & 4 deletions test/Controller/AboutPublishingWithElifeControllerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -154,10 +154,10 @@ public function it_has_metadata()
$this->assertSame('eLife welcomes the submission of Research Articles, Short Reports, Tools and Resources articles, Research Advances, Scientific Correspondence and Review Articles in the subject areas below.', $crawler->filter('meta[property="og:description"]')->attr('content'));
$this->assertSame('eLife welcomes the submission of Research Articles, Short Reports, Tools and Resources articles, Research Advances, Scientific Correspondence and Review Articles in the subject areas below.', $crawler->filter('meta[name="description"]')->attr('content'));
$this->assertSame('summary', $crawler->filter('meta[name="twitter:card"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('280', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('200', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertEmpty($crawler->filter('meta[name="dc.identifier"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.relation.ispartof"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.title"]'));
Expand Down
8 changes: 4 additions & 4 deletions test/Controller/AboutResearchCultureControllerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ public function it_has_metadata()
$this->assertSame('eLife recognises that reforming research communication depends on improving research culture.', $crawler->filter('meta[property="og:description"]')->attr('content'));
$this->assertSame('eLife recognises that reforming research communication depends on improving research culture.', $crawler->filter('meta[name="description"]')->attr('content'));
$this->assertSame('summary', $crawler->filter('meta[name="twitter:card"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('280', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('200', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertEmpty($crawler->filter('meta[name="dc.identifier"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.relation.ispartof"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.title"]'));
Expand Down
8 changes: 4 additions & 4 deletions test/Controller/AboutTechnologyControllerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ public function it_has_metadata()
$this->assertSame('eLife develops and invests in technology that enhances the sharing and use of research results online.', $crawler->filter('meta[property="og:description"]')->attr('content'));
$this->assertSame('eLife develops and invests in technology that enhances the sharing and use of research results online.', $crawler->filter('meta[name="description"]')->attr('content'));
$this->assertSame('summary', $crawler->filter('meta[name="twitter:card"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('280', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('200', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertEmpty($crawler->filter('meta[name="dc.identifier"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.relation.ispartof"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.title"]'));
Expand Down
8 changes: 4 additions & 4 deletions test/Controller/AlertsControllerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -99,10 +99,10 @@ public function it_has_metadata()
$this->assertSame('Stay in touch with eLife efforts to support the community and open science as well as new research. Choose your feeds and preferred ways to connect below.', $crawler->filter('meta[property="og:description"]')->attr('content'));
$this->assertSame('Stay in touch with eLife efforts to support the community and open science as well as new research. Choose your feeds and preferred ways to connect below.', $crawler->filter('meta[name="description"]')->attr('content'));
$this->assertSame('summary', $crawler->filter('meta[name="twitter:card"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('280', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('200', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertEmpty($crawler->filter('meta[name="dc.identifier"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.relation.ispartof"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.title"]'));
Expand Down
8 changes: 4 additions & 4 deletions test/Controller/AnnualReportsControllerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,10 @@ public function it_has_metadata()
$this->assertEmpty($crawler->filter('meta[property="og:description"]'));
$this->assertEmpty($crawler->filter('meta[name="description"]'));
$this->assertSame('summary', $crawler->filter('meta[name="twitter:card"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-600x600@1.png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('600', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[name="twitter:image"]')->attr('content'));
$this->assertSame('http://localhost/'.ltrim(self::$kernel->getContainer()->get('elife.assets.packages')->getUrl('assets/images/social/icon-[email protected].png'), '/'), $crawler->filter('meta[property="og:image"]')->attr('content'));
$this->assertSame('280', $crawler->filter('meta[property="og:image:width"]')->attr('content'));
$this->assertSame('200', $crawler->filter('meta[property="og:image:height"]')->attr('content'));
$this->assertEmpty($crawler->filter('meta[name="dc.identifier"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.relation.ispartof"]'));
$this->assertEmpty($crawler->filter('meta[name="dc.title"]'));
Expand Down
Loading

0 comments on commit b149517

Please sign in to comment.