-
Notifications
You must be signed in to change notification settings - Fork 23
DemoAlerts() - show that prompt was set #371
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
I have some further refactoring for this DemoAlerts(). |
As for me it is all in this PR, please review again and merge if you agree with my opinion about the comments:
|
Why is this needed here? I don't see the purpose of using "storage" in the middle of an Alerts demo. |
To show that the given text entered to prompt was properly send to browser. |
Sorry, but I don't understand how this code demonstrates that. With this line --
you introduce advanced concepts that have nothing to do with _WD_Alert IMO. |
Yes it is more advanced than only showing prompt. |
I've run the revised demo, but I still don't get the point of this change. You are storing and retrieving the value that was changed with |
this part: Lines 531 to 532 in a41396b
popup prompt to input data, which are saved in browser Storage
and this part: Lines 542 to 544 in a41396b
check what trully was received and save in browser Storage I call this EDIT: |
AFAICS you aren't validating the functionality of _WD_Alert. Therefore, this doesn't belong in DemoAlerts function.
Also doesn't belong here. |
So how we can validate that var userinput = prompt('User Prompt 1', 'Default value') browser get the value provided by entering string to the prompt ? |
You need a webpage that accepts the user input and then displays it on screen like they do here. I haven't tried this yet, but I was thinking that you could open a new tab and then use _WD_ExecuteScript to update the tab's source code to mimic the behavior of that website without the frames. |
Why not simply use this webpage ? |
Pull request
Proposed changes
this PR is only related to the comment that describe in the specific case what kind of expected result should be to check Alert status
Checklist
Types of changes
What is the current behavior?
; check status before displaying Alert
What is the new behavior?
; check status before displaying Alert - this should set @error as there is no any Alert displayed yet
Additional context
I was checking examples for this ISSUE #254
System under test
not related