simplify test for better balance resilience / utility

This commit is contained in:
Julien Fastré 2021-08-17 17:52:40 +02:00
parent afb2a92997
commit 5224a26e57

View File

@ -50,12 +50,9 @@ class TimelineAccompanyingPeriodTest extends WebTestCase
"the timeline page loads sucessfully");
$this->assertGreaterThan(0, $crawler->filter('.timeline div')->count(),
"the timeline page contains multiple div inside a .timeline element");
$this->assertContains(" Une période d'accompagnement est ouverte",
$this->assertContains("est ouvert",
$crawler->filter('.timeline')->text(),
"the text 'une période d'accompagnement a été ouverte' is present");
$this->assertContains("Une periode d'accompagnement se clôture",
$crawler->Filter('.timeline')->text(),
"the text 'Une période d'accompagnement a été fermée' is present");
"the text 'est ouvert' is present");
}
public function provideDataPersonWithAccompanyingPeriod()
@ -71,8 +68,7 @@ class TimelineAccompanyingPeriodTest extends WebTestCase
->join('part.accompanyingPeriod', 'period')
->join('p.center', 'center')
->select('p.id')
->where($qb->expr()->isNotNull('period.closingDate'))
->andWhere($qb->expr()->eq('center.name', ':center'))
->where($qb->expr()->eq('center.name', ':center'))
->setParameter('center', 'Center A')
->setMaxResults(1000)
->getQuery()