[MGNLTEST-45] Non modal notifications should not interfere with UI tests Created: 10/Jan/20  Updated: 08/Jul/20  Resolved: 21/Jan/20

Status: Closed
Project: Magnolia Test Framework
Component/s: None
Affects Version/s: None
Fix Version/s: 1.0

Type: Improvement Priority: Neutral
Reporter: Federico Grilli Assignee: Federico Grilli
Resolution: Not an issue Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Date of First Response:
Epic Link: core-TF-features-bugs-improvements
Sprint: now
Story Points: 3

 Description   

Here is another example / a few lines of codes, where tests always fail:

 contentApp.clickRow(titleInitialVersion)
      .hitAction("Publish") 
      .hitAction("Edit page")   
      .hitAction("Edit page properties");

The "problem" is publish which will may take some time plus displays a "banner" ("Successfully bla bla ...").
These banners, as well as other similar types of notification, interfere with the DOM in a way, that our locators typically fail, as long as such a message is present.
In some cases it is fine - actually required - to confirm the message, which disappear then.
But the banner from publishing has no button to confirm (however, there is a [x] to close it), and the message automatically disappear after a few seconds.

One possible workaround is to discard such notifs, e.g.

expect.notification()
                .withMessage("Role successfully deleted.") 
                .discard();

However, let's see if we can avoid test writers to write such code, unless they actually want to check that such a notif is displayed.



 Comments   
Comment by Christoph Meier [ 14/Jan/20 ]

TIMEBOX it for the time being (w/ 3SP)

Comment by Federico Grilli [ 21/Jan/20 ]

Added test, modified existing one to show it's not an issue.

Generated at Mon Feb 12 07:45:01 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.