How do I click a button in a popup window during an ATF test?

guided by books
Giga Contributor

I am working in London, creating a KB article, saving, publishing, then trying to retire.  After clicking "Retire", a popup appears to make sure the user had already used "Check Links".  I have not yet found the way to send a click to that popup window, so the test continues on to attempt to "Unretire".  This fails because the KB article is still Published, the popup prevents the retire from completing.

Any suggestions on where to find the answer?

Thanks

1 ACCEPTED SOLUTION

Jonathan,

I just searched the ID of the OK button and its ok_button (all small caps). Sorry for the wrong button name, I got it from the documentation directly but looks like the documentation page has a mistake.

Give it a shot. 

Reference: Form test step: Click Modal Button

 

Thank you,

Aman Gurram

View solution in original post

15 REPLIES 15

ARG645
Tera Guru

is this Popup a Glide Modal window ? 

I believe this is a Glide Modal.  (still learning the under the hood terminology of some of these things)

Here is the script that is triggered by clicking the Retire button:

function retireArticle(){
	//placeholder for future reminder did you use the check links button first?
		
	var dialog = new GlideModal('glide_confirm_standard');
	dialog.setTitle(new GwtMessage().getMessage('Confirmation'));
	dialog.setPreference('warning', true);
	dialog.setPreference('title', new GwtMessage().getMessage("You must use the Check Links button to make sure other articles are not linked to this article. Click OK below if you have already checked this article for links."));
	dialog.setPreference('onPromptComplete', check_worknote_onConfirm);
	dialog.render();
}

I am not sure if this works in previous versions, but if you're on London.

Click Modal Button

Okay, from looking at your code, I can say that its a Glide Modal Window. 

So follow the below steps. 

1. Add Test Step

2. Form -> Click Modal Button

3. Specify the UI page as 

glide_confirm_standard

4. Specify the Button as OK_button

5. Fill in other details according to your needs. 

 

Below is a screen shot of step 3 and 4 

find_real_file.png

 

Thank you,

Aman Gurram