Source:
public void init() { Package model = editorFixture.getModel(); assertNotNull("The model cannot be null", model); assertFalse(model.getProfileApplications().isEmpty()); labelProviderService = new LabelProviderServiceImpl(); assertNotNull("The service should not be null.", labelProviderService); imageRegistry = Activator.getDefault().getImageRegistry(); assertNotNull("The Image registry should not be null.", imageRegistry); profile = model.getAppliedProfile(PROFILE_NAME); assertEquals("Profile is not the one Expected", PROFILE_NAME, profile.getName()); class1 = model.getMember(CLASS_1_NAME); assertTrue("The element is a Class", class1 instanceof Class); assertEquals("Element is not the one expected", CLASS_1_NAME, ((NamedElement) class1).getName()); class2 = model.getMember(CLASS_2_NAME); assertTrue("The element is a Class", class2 instanceof Class); assertEquals("Element is not the one expected", CLASS_2_NAME, ((NamedElement) class2).getName()); class3 = model.getMember(CLASS_3_NAME); assertTrue("The element is a Class", class3 instanceof Class); assertEquals("Element is not the one expected", CLASS_3_NAME, ((NamedElement) class3).getName()); class4 = model.getMember(CLASS_4_NAME); assertTrue("The element is a Class", class4 instanceof Class); assertEquals("Element is not the one expected", CLASS_4_NAME, ((NamedElement) class4).getName()); stereotype1 = profile.getOwnedStereotype(STEREOTYPE_1_NAME); assertEquals("Stereotype is not the one expected", STEREOTYPE_1_NAME, stereotype1.getName()); stereotype2 = profile.getOwnedStereotype(STEREOTYPE_2_NAME); assertEquals("Stereotype is not the one expected", STEREOTYPE_2_NAME, stereotype2.getName()); stereotype3 = profile.getOwnedStereotype(STEREOTYPE_3_NAME); assertEquals("Stereotype is not the one expected", STEREOTYPE_3_NAME, stereotype3.getName()); }

Target:
public void init() { Package model = editorFixture.getModel(); assertNotNull("The model cannot be null", model); assertFalse("The model must contain ProfileApplications references.", model.getProfileApplications().isEmpty()); imageRegistry = Activator.getDefault().getImageRegistry(); assertNotNull("The Image registry should not be null.", imageRegistry); profile = model.getAppliedProfile(PROFILE_NAME); assertEquals("Profile is not the one Expected", PROFILE_NAME, profile.getName()); class1 = model.getMember(CLASS_1_NAME); assertTrue("The element is a Class", class1 instanceof Class); assertEquals("Element is not the one expected", CLASS_1_NAME, class1.getName()); class2 = model.getMember(CLASS_2_NAME); assertTrue("The element is a Class", class2 instanceof Class); assertEquals("Element is not the one expected", CLASS_2_NAME, class2.getName()); class3 = model.getMember(CLASS_3_NAME); assertTrue("The element is a Class", class3 instanceof Class); assertEquals("Element is not the one expected", CLASS_3_NAME, class3.getName()); class4 = model.getMember(CLASS_4_NAME); assertTrue("The element is a Class", class4 instanceof Class); assertEquals("Element is not the one expected", CLASS_4_NAME, class4.getName()); stereotype1 = profile.getOwnedStereotype(STEREOTYPE_1_NAME); assertEquals("Stereotype is not the one expected", STEREOTYPE_1_NAME, stereotype1.getName()); stereotype2 = profile.getOwnedStereotype(STEREOTYPE_2_NAME); assertEquals("Stereotype is not the one expected", STEREOTYPE_2_NAME, stereotype2.getName()); stereotype3 = profile.getOwnedStereotype(STEREOTYPE_3_NAME); assertEquals("Stereotype is not the one expected", STEREOTYPE_3_NAME, stereotype3.getName()); }