@Test
public void testStoreTo() throws IOException, StorageFormatException, ResumeFailedException, GeneralSecurityException {
File tempFile = File.createTempFile("test-storeto", ".tmp", base);
byte[] buf = new byte[4096];
Random r = new Random(1267612);
r.nextBytes(buf);
FileBucket fb = new FileBucket(tempFile, false, false, false, true);
EncryptedRandomAccessBucket erab = new EncryptedRandomAccessBucket(types[0], fb, secret);
OutputStream os = erab.getOutputStream();
os.write(buf, 0, buf.length);
os.close();