mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
fix redirection after creating accompanying course in test
This commit is contained in:
parent
1410213258
commit
f49c54d51f
@ -28,7 +28,7 @@ class AccompanyingCourseControllerTest extends WebTestCase
|
|||||||
$this->assertResponseRedirects();
|
$this->assertResponseRedirects();
|
||||||
$location = $this->client->getResponse()->headers->get('Location');
|
$location = $this->client->getResponse()->headers->get('Location');
|
||||||
|
|
||||||
$this->assertEquals(1, \preg_match("|^\/[^\/]+\/parcours/([\d]+)/show$|", $location));
|
$this->assertEquals(1, \preg_match("|^\/[^\/]+\/parcours/([\d]+)/edit$|", $location));
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -48,7 +48,7 @@ class AccompanyingCourseControllerTest extends WebTestCase
|
|||||||
$location = $this->client->getResponse()->headers->get('Location');
|
$location = $this->client->getResponse()->headers->get('Location');
|
||||||
$matches = [];
|
$matches = [];
|
||||||
|
|
||||||
$this->assertEquals(1, \preg_match("|^\/[^\/]+\/parcours/([\d]+)/show$|", $location, $matches));
|
$this->assertEquals(1, \preg_match("|^\/[^\/]+\/parcours/([\d]+)/edit$|", $location, $matches));
|
||||||
$id = $matches[1];
|
$id = $matches[1];
|
||||||
|
|
||||||
$period = self::$container->get(EntityManagerInterface::class)
|
$period = self::$container->get(EntityManagerInterface::class)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user