public function assertVersion()
    {
        $process = $this->createProtocVersionProcess();

        // Check if protoc is available
        $process->mustRun();

        $return = $process->getExitCode();
        $result = trim($process->getOutput());

        if (0 !== $return && 1 !== $return) {
            throw new UnexpectedValueException("Unable to find the protoc command. Please make sure it's installed and available in the path.");
        }

        if ( ! preg_match('/[0-9\.]+/', $result, $match)) {
            throw new UnexpectedValueException("Unable to get protoc command version. Please make sure it's installed and available in the path.");
        }

        if (version_compare($match[0], $this->version) < 0) {
            throw new UnexpectedValueException("The protoc command in your system is too old. Minimum version required is '{$this->version}' but found '$result'.");
        }
    }