use of org.eclipse.osgi.service.resolver.ExportPackageDescription in project rt.equinox.framework by eclipse.
the class TestGenerated_001 method checkWiringState_8.
// end method
public void checkWiringState_8() {
ExportPackageDescription[] exports = null;
exports = null;
exports = bundle_8.getResolvedImports();
assertNotNull("export array is unexpectedly null", exports);
assertTrue("export array is unexpectedly empty", exports.length > 0);
for (int i = 0; i < exports.length; i++) {
ExportPackageDescription exp = exports[i];
String exportPackageName = exp.getName();
assertNotNull("package name is null", exportPackageName);
if (exportPackageName.equals("a2")) {
assertNotNull("Package [a2] is not wired when it should be ", exp.getExporter());
assertEquals("Package [a2] is wired incorrectly ", exp.getExporter(), bundle_8);
} else if (exportPackageName.equals("a1")) {
assertNotNull("Package [a1] is not wired when it should be ", exp.getExporter());
assertEquals("Package [a1] is wired incorrectly ", exp.getExporter(), bundle_3);
} else if (exportPackageName.equals("a3")) {
assertNotNull("Package [a3] is not wired when it should be ", exp.getExporter());
assertEquals("Package [a3] is wired incorrectly ", exp.getExporter(), bundle_6);
}
}
// end for
}
use of org.eclipse.osgi.service.resolver.ExportPackageDescription in project rt.equinox.framework by eclipse.
the class TestGenerated_001 method checkWiringState_7.
// end method
public void checkWiringState_7() {
ExportPackageDescription[] exports = null;
exports = null;
exports = bundle_7.getResolvedImports();
assertNotNull("export array is unexpectedly null", exports);
assertTrue("export array is unexpectedly empty", exports.length > 0);
for (int i = 0; i < exports.length; i++) {
ExportPackageDescription exp = exports[i];
String exportPackageName = exp.getName();
assertNotNull("package name is null", exportPackageName);
if (exportPackageName.equals("a2")) {
assertNotNull("Package [a2] is not wired when it should be ", exp.getExporter());
assertEquals("Package [a2] is wired incorrectly ", exp.getExporter(), bundle_8);
} else if (exportPackageName.equals("a1")) {
assertNotNull("Package [a1] is not wired when it should be ", exp.getExporter());
assertEquals("Package [a1] is wired incorrectly ", exp.getExporter(), bundle_3);
} else if (exportPackageName.equals("a3")) {
assertNotNull("Package [a3] is not wired when it should be ", exp.getExporter());
assertEquals("Package [a3] is wired incorrectly ", exp.getExporter(), bundle_6);
}
}
// end for
}
use of org.eclipse.osgi.service.resolver.ExportPackageDescription in project rt.equinox.framework by eclipse.
the class TestGenerated_001 method checkWiringState_3.
// end method
public void checkWiringState_3() {
ExportPackageDescription[] exports = null;
exports = null;
exports = bundle_3.getResolvedImports();
assertNotNull("export array is unexpectedly null", exports);
assertTrue("export array is unexpectedly empty", exports.length > 0);
for (int i = 0; i < exports.length; i++) {
ExportPackageDescription exp = exports[i];
String exportPackageName = exp.getName();
assertNotNull("package name is null", exportPackageName);
if (exportPackageName.equals("a2")) {
assertNotNull("Package [a2] is not wired when it should be ", exp.getExporter());
assertEquals("Package [a2] is wired incorrectly ", exp.getExporter(), bundle_8);
} else if (exportPackageName.equals("a1")) {
assertNotNull("Package [a1] is not wired when it should be ", exp.getExporter());
assertEquals("Package [a1] is wired incorrectly ", exp.getExporter(), bundle_3);
} else if (exportPackageName.equals("a3")) {
assertNotNull("Package [a3] is not wired when it should be ", exp.getExporter());
assertEquals("Package [a3] is wired incorrectly ", exp.getExporter(), bundle_6);
}
}
// end for
}
use of org.eclipse.osgi.service.resolver.ExportPackageDescription in project rt.equinox.framework by eclipse.
the class TestDynamic_004 method testTest_003.
public void testTest_003() {
State state = buildEmptyState();
StateObjectFactory sof = StateObjectFactory.defaultFactory;
bundle_1 = create_bundle_1(sof);
bundle_2 = create_bundle_2(sof);
bundle_3 = create_bundle_3(sof);
bundle_4 = create_bundle_4(sof);
// ***************************************************
// stage a
// expect to pass =true
// ***************************************************
addBundlesToState_a(state);
// ***************************************************
try {
state.resolve();
} catch (Throwable t) {
fail("unexpected exception class=" + t.getClass().getName() + " message=" + t.getMessage());
return;
}
checkBundlesResolved_a();
checkWiring_a();
// Dynamics
ExportPackageDescription exp = state.linkDynamicImport(bundle_1, "q");
assertNotNull("Package [q] is not wired when it should be ", exp);
assertEquals("Package [q] is wired incorrectly ", exp.getExporter(), bundle_3);
}
use of org.eclipse.osgi.service.resolver.ExportPackageDescription in project rt.equinox.framework by eclipse.
the class TestDynamic_004 method checkWiringState_1.
// end of method
public void checkWiringState_1() {
ExportPackageDescription[] exports = bundle_1.getResolvedImports();
assertNotNull("export array is unexpectedly null", exports);
assertTrue("export array is unexpectedly empty", exports.length > 0);
for (int i = 0; i < exports.length; i++) {
ExportPackageDescription exp = exports[i];
String exportPackageName = exp.getName();
assertNotNull("package name is null", exportPackageName);
if (exportPackageName.equals("p")) {
assertNotNull("Package [p] is not wired when it should be ", exp.getExporter());
assertEquals("Package [p] is wired incorrectly ", exp.getExporter(), bundle_2);
}
}
// end for
}
Aggregations