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

Add automated test for "Delete user with Script or Programming Rights"

    XMLWordPrintable

Details

    • Unknown

    Description

      The manual test is here: https://test.xwiki.org/xwiki/bin/view/Administration%20Tests/Delete%20user%20with%20Script%20or%20Programming%20Rights

      The test verifies that if deleting an user with Script and/or Programming rights displays a warning properly.

      Matrix discussion: https://matrix.to/#/!ikPtGZaGWtyblizzlR:matrix.xwiki.com/$16166704539725sfxVi:matrix.xwiki.com?via=matrix.org&via=matrix.xwiki.com&via=dodsorf.as

      Vincent Massol: Ilie Andriuta: I'm on it to verify
      one trick you should know to find out if a test exists:
      try finding the Release Change item corresponding to it
      Found it here I think: https://www.xwiki.org/xwiki/bin/view/ReleaseNotes/Data/XWiki/11.3RC1/Change002/
      this gives you the version of XWiki where the feature or improvement was introduced: XWiki 11.3RC1 here
      Search jira to find the jira issue corresponding to it
      Here it would be fixVersion = 11.3-rc-1 and category = 10000which leads to https://jira.xwiki.org/browse/XWIKI-16361
      Check the commits (in the jira issue) and see if a test was modified or added
      commit 1= https://github.com/xwiki/xwiki-platform/commit/48cf8efe3e3f98c8f85c663242dffafecd79140c
      commit 2= https://github.com/xwiki/xwiki-platform/commit/41d47d0d540d158000b4ac8c828276baf3ae55c0
      so
      commit1 shows no tests
      and commit2 shows some test change in UsersGroupsRightsManagementTest.java but nothing about testing the change
      unfortunately ...
      We can also see Marius Dumitru Florea did this
      so you also get the name of the dev to check with
      so basically all this new velocity code is untested Marius Dumitru Florea : https://github.com/xwiki/xwiki-platform/commit/48cf8efe3e3f98c8f85c663242dffafecd79140c#diff-c97001dbb0891398a72b4ba8c826749448f915c3fadcb26543a5cae0b5ea0970R171-R498
      right?
      Ilie Andriuta: Thanks for the trick, but this is for fairly new features, right?
      Vincent Massol: Ilie Andriuta: yes
      since the time we started introducing relase notes
      Ilie Andriuta: there are more places where a test can be found though
      Vincent Massol: so not that recent either
      Ilie Andriuta: yes it's not perfect, it's just one more trick
      (that's how I did it the analysis here for ex)
      Marius Dumitru Florea: I don't recall, but judging by

      and commit2 shows some test change in UsersGroupsRightsManagementTest.java but nothing about testing the change

      I'd say it's not tested

      Ilie Andriuta: I should create a task for it then
      thanks

       

       

      Attachments

        Activity

          People

            Unassigned Unassigned
            iandriuta Ilie Andriuta
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: