public function collectEnvVars(array $env) { $envCollector = new CiEnvVarsCollector($this->config); try { $this->jsonFile->fillJobs($envCollector->collect($env)); } catch (\Satooshi\Bundle\CoverallsV1Bundle\Entity\Exception\RequirementsNotSatisfiedException $e) { $e->setReadEnv($envCollector->getReadEnv()); throw $e; } return $this; }
/** * @test * @depends shouldCollectUnsupportedEnvVars */ public function shouldHaveReadEnvAfterCollectUnsupportedEnvVars(CiEnvVarsCollector $object) { $readEnv = $object->getReadEnv(); $this->assertCount(1, $readEnv); $this->assertArrayHasKey('COVERALLS_REPO_TOKEN', $readEnv); }