@Test
public void pemOf_convertsAnObjectToPemString() throws IOException {

  final String pemString = CertificateFormatter.pemOf(keyPair);
  assertThat(pemString, startsWith("-----BEGIN RSA PRIVATE KEY-----"));
  assertThat(pemString, endsWith("-----END RSA PRIVATE KEY-----\n"));
}