Using ObjectDB in embedded mode, I tried the following while test running:
EntityManagerFactory emf = Persistence.createEntityManagerFactory("objectdb:punkter.odb;drop");
The drop-codeword does not seem to work - I must manually delete the database file each time. I get no errors nor warnings.