public void testDetectExistingSnapshotFromUnknownSnapshotManager() throws Exception {
Prevayler<StringBuffer> first = createPrevayler("xstreamsnapshot", new XStreamSerializer());
appendTakeSnapshotAndClose(first);
try {
createPrevayler("snapshot", new JavaSerializer());
fail();
} catch (IOException e) {
// This is good because if we only looked for .snapshot files we could silently ignore an existing snapshot.
assertTrue("Actual message was <" + e.getMessage() + ">",
e.getMessage().endsWith("0000000000000000002.xstreamsnapshot cannot be read; only [snapshot] supported"));