public function test signCertificateRequest with subject alternative names()
{
$dummyDistinguishedName = new DistinguishedName('acmephp.com', 'FR', 'france', 'Paris', 'acme', 'IT', '*****@*****.**', ['www.acmephp.com']);
$dummyKeyPair = (new KeyPairGenerator())->generateKeyPair(1024);
$result = $this->service->signCertificateRequest(new CertificateRequest($dummyDistinguishedName, $dummyKeyPair));
$this->assertInternalType('string', $result);
$this->assertContains('-----BEGIN CERTIFICATE REQUEST-----', $result);
$csrResult = openssl_csr_get_subject($result, false);
$this->assertSame(['commonName' => 'acmephp.com', 'countryName' => 'FR', 'stateOrProvinceName' => 'france', 'localityName' => 'Paris', 'organizationName' => 'acme', 'organizationalUnitName' => 'IT', 'emailAddress' => '*****@*****.**'], $csrResult);
}