Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-25058

TagIT#addExistingTag is flickering

    XMLWordPrintable

Details

    • Unknown
    • org.xwiki.tag.test.ui.AllIT$NestedTagIT#addExistingTag

    Description

      The functional test org.xwiki.tag.test.ui.AllIT$NestedTagIT#addExistingTag fails intermittently on ci.xwiki.org.

      Occurrence

      Error

      org.openqa.selenium.ElementClickInterceptedException: element click intercepted: Element <input class="button button-add-tag" type="submit" value="Add"> is not clickable at point (69, 364). Other element would receive the click: <li class="xitem " style="background-image: url(&quot;http://xwikiweb0:8080/xwiki/resources/icons/silk/tag_yellow.png?cache-version=1790728190000&quot;); background-repeat
      	at org.xwiki.tag.test.po.AddTagsPane.add(AddTagsPane.java:86)
      	at org.xwiki.tag.test.ui.TagIT.addExistingTag(TagIT.java:152)
      

      Analysis

      The click on the Add button is intercepted by an li.xitem, i.e. the tag suggest dropdown (XWiki.widgets.Suggest attached to the tag input in tags.js, rendered inside tag-add-form-suggest). The dropdown only shows when the typed tag already exists, which is precisely the second setTags(tag) of this test, and it appears after the key-up delay plus an AJAX round trip. AddTagsPane#add() clicks the button without waiting for the suggestions or dismissing them, so when the dropdown opens between sendKeys and click() the click lands on it.

      Possible fix

      Dismiss the suggestions (e.g. press Escape) or wait for them in AddTagsPane#setTags, before clicking Add.

      Attachments

        Activity

          People

            Unassigned Unassigned
            mleduc Manuel Leduc
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: