oos.close();
Assertions.assertThat(out.toByteArray().length).isGreaterThan(0);
// deserialize
final InputStream in = new ByteArrayInputStream(out.toByteArray());
final ObjectInputStream ois = new ObjectInputStream(in);
final WindowsAccount copy = (WindowsAccount) ois.readObject();
// test
Assert.assertEquals(this.windowsAccount, copy);
Assert.assertEquals(this.windowsAccount.getDomain(), copy.getDomain());
Assert.assertEquals(this.windowsAccount.getFqn(), copy.getFqn());
Assert.assertEquals(this.windowsAccount.getName(), copy.getName());
Assert.assertEquals(this.windowsAccount.getSidString(), copy.getSidString());
}