public function setEnvironment($env) { if ($this->started) { throw new LogicException('Puli is already started'); } Assert::oneOf($env, Environment::all(), 'The environment must be one of: %2$s. Got: %s'); $this->env = $env; }