BundleVersion bv2 = createBundleVersion(b2.getName(), "1.0", b2);
assertNotNull(bv2);
BundleFile b2f1 = bundleManager.addBundleFileViaByteArray(overlord, bv2.getId(), TEST_PREFIX + "-file1", "1.0",
null, "Bundle #2 File # 1".getBytes());
BundleFileCriteria bfc = new BundleFileCriteria();
bfc.addFilterBundleVersionId(bv1.getId());
PageList<BundleFile> bundleFiles = bundleManager.findBundleFilesByCriteria(overlord, bfc);
assert bundleFiles.size() == 1 : bundleFiles;
assert bundleFiles.get(0).getId() == b1f1.getId() : bundleFiles;
bfc = new BundleFileCriteria();
bfc.addFilterBundleVersionId(bv2.getId());
bundleFiles = bundleManager.findBundleFilesByCriteria(overlord, bfc);
assert bundleFiles.size() == 1 : bundleFiles;
assert bundleFiles.get(0).getId() == b2f1.getId() : bundleFiles;
assert b1f1.getId() != b2f1.getId() : "should have been different bundle files";