@@ 47-57 (lines=11) @@ | ||
44 | $configurationServiceName = $creationOptions['configuration']; |
|
45 | } |
|
46 | ||
47 | if ($appServiceLocator->has($configurationServiceName)) { |
|
48 | /** @var Configuration $configuration */ |
|
49 | $configuration = $appServiceLocator->get($configurationServiceName); |
|
50 | } elseif (class_exists($configurationServiceName)) { |
|
51 | $r = new ReflectionClass($configurationServiceName); |
|
52 | /** @var Configuration $configuration */ |
|
53 | $configuration = $r->newInstance(); |
|
54 | } else { |
|
55 | $errMsg = 'Invalid fixture executor configuration'; |
|
56 | throw new Exception\RuntimeException($errMsg); |
|
57 | } |
|
58 | ||
59 | $builderServiceName = FixtureExecutorBuilderInterface::class; |
|
60 | if (array_key_exists('builder', $creationOptions)) { |
|
@@ 63-73 (lines=11) @@ | ||
60 | if (array_key_exists('builder', $creationOptions)) { |
|
61 | $builderServiceName = $creationOptions['builder']; |
|
62 | } |
|
63 | if ($appServiceLocator->has($builderServiceName)) { |
|
64 | /** @var FixtureExecutorBuilderInterface $builder */ |
|
65 | $builder = $appServiceLocator->get($builderServiceName); |
|
66 | } elseif (class_exists($builderServiceName)) { |
|
67 | $r = new ReflectionClass($builderServiceName); |
|
68 | /** @var FixtureExecutorBuilderInterface $builder */ |
|
69 | $builder = $r->newInstance(); |
|
70 | } else { |
|
71 | $errMsg = 'Invalid fixture executor builder'; |
|
72 | throw new Exception\RuntimeException($errMsg); |
|
73 | } |
|
74 | ||
75 | ||
76 | /** @var FixtureInitializerManagerInterface $fixtureInitializerManager */ |