function deleteBusinessPartner() {
				When.waitFor({
					controlType : "sap.m.Button",
					id : "deleteBusinessPartner",
					viewName : sViewName,
					success : function (oButton) {
						new Press().executeOn(oButton);
					}
				});

				Then.waitFor({
					controlType : "sap.m.Dialog",
					matchers : new Properties({icon : "sap-icon://sys-enter-2"}),
					success : function (aControls) {
						new Press().executeOn(aControls[0].getButtons()[0]); // confirm success
						Opa5.assert.ok(true, "Business Partner deleted");
					}
				});
			}
// Click on deleteBusinessPartner button, confirm the success dialog
Click on deleteBusinessPartner button, confirm the success dialog
Click on deleteBusinessPartner button confirm the success dialog
function deleteBusinessPartner() {
				When.waitFor({
					controlType : "sap.m.Button",
					id : "deleteBusinessPartner",
					viewName : sViewName,
					success : function (oButton) {
						new Press().executeOn(oButton);
					}
				});
				Then.waitFor({
					controlType : "sap.m.Dialog",
					matchers : new Properties({icon : "sap-icon://sys-enter-2"}),
					success : function (aControls) {
						new Press().executeOn(aControls[0].getButtons()[0]); 
						Opa5.assert.ok(true, "Business Partner deleted");
					}
				});
			}
function deleteBusinessPartner ( ) { When . waitFor ( { controlType : "sap.m.Button" , id : "deleteBusinessPartner" , viewName : sViewName , success : function ( oButton ) { new Press ( ) . executeOn ( oButton ) ; } } ) ; Then . waitFor ( { controlType : "sap.m.Dialog" , matchers : new Properties ( { icon : "sap-icon://sys-enter-2" } ) , success : function ( aControls ) { new Press ( ) . executeOn ( aControls [ 0 ] . getButtons ( ) [ 0 ] ) ; Opa5 . assert . ok ( true , "Business Partner deleted" ) ; } } ) ; }
Click on deleteBusinessPartner button, confirm the success dialog
Click on deleteBusinessPartner button confirm the success dialog
// confirm success