@@ 84-95 (lines=12) @@ | ||
81 | * |
|
82 | * @return bool |
|
83 | */ |
|
84 | private function testMemoryLimit() |
|
85 | { |
|
86 | $output = $this->testCliRuntime('echo ini_get(\'memory_limit\');'); |
|
87 | if ('-1' !== $output) { |
|
88 | if ($this->testOverride('echo ini_get(\'memory_limit\');', '-d memory_limit=1G', '1G')) { |
|
89 | $this->getAutoConfig()->addCommandLineArgument('-d memory_limit=1G'); |
|
90 | $this->log->writeln('Will override memory_limit of ' . $output . ' with 1G.'); |
|
91 | } |
|
92 | } |
|
93 | ||
94 | return true; |
|
95 | } |
|
96 | ||
97 | /** |
|
98 | * Test if raising the memory limit is needed. |
|
@@ 102-113 (lines=12) @@ | ||
99 | * |
|
100 | * @return bool |
|
101 | */ |
|
102 | private function testMaxExecutionTime() |
|
103 | { |
|
104 | $output = $this->testCliRuntime('echo ini_get(\'max_execution_time\');'); |
|
105 | if (900 > intval($output)) { |
|
106 | if ($this->testOverride('echo ini_get(\'max_execution_time\');', '-d max_execution_time=900', '900')) { |
|
107 | $this->getAutoConfig()->addCommandLineArgument('-d max_execution_time=900'); |
|
108 | $this->log->writeln('Will override max_execution_time of ' . $output . ' with 900 seconds.'); |
|
109 | } |
|
110 | } |
|
111 | ||
112 | return true; |
|
113 | } |
|
114 | ||
115 | /** |
|
116 | * Test if overriding a parameter works. |