src/Oro/Bundle/AddressBundle/Migrations/Data/ORM/LoadCountryData.php 1 location
|
@@ 94-103 (lines=10) @@
|
91 |
|
* @return array |
92 |
|
* @throws \LogicException |
93 |
|
*/ |
94 |
|
protected function getDataFromFile($fileName) |
95 |
|
{ |
96 |
|
if (!$this->isFileAvailable($fileName)) { |
97 |
|
throw new \LogicException('File ' . $fileName . 'is not available'); |
98 |
|
} |
99 |
|
|
100 |
|
$fileName = realpath($fileName); |
101 |
|
|
102 |
|
return Yaml::parse(file_get_contents($fileName)); |
103 |
|
} |
104 |
|
|
105 |
|
/** |
106 |
|
* @param string $locale |
src/Oro/Bundle/WorkflowBundle/Tests/Unit/Configuration/WorkflowConfigurationTest.php 1 location
|
@@ 28-35 (lines=8) @@
|
25 |
|
/** |
26 |
|
* @return array |
27 |
|
*/ |
28 |
|
protected function getInputConfiguration() |
29 |
|
{ |
30 |
|
$fileName = __DIR__ . '/Stub/CorrectConfiguration/Resources/config/workflow.yml'; |
31 |
|
$this->assertFileExists($fileName); |
32 |
|
$data = Yaml::parse(file_get_contents($fileName)) ? : []; |
33 |
|
|
34 |
|
return current($data); |
35 |
|
} |
36 |
|
|
37 |
|
/** |
38 |
|
* @return array |