•  
     
    story #22226 edit test execution comments
Summary
test executor
edit test execution comments

I can prove test execution

Historical behaviour

As of today, comment associated to a test execution is strongly associated to the recording of the status (passed/failed/blocked). It means that text executor is supposed to:

  1. notice a that the test/step is, for instance, failling
  2. write a comment
  3. click on "failed" to record both the failure as well as saving the comment

More than often though, the actual steps are:

  1. notice a that the test/step is failling
  2. click on "failed"
  3. add a comment about the failure
  4. click again on "failed" to save the comment

New behaviour

It should be possible to edit/change a comment in order to:

  • be more specific about the failure mode
  • clear / rewrite comment because the test was re-executed

This means a decoupling between the comment and the status. This introduce the risk of having a comment no longer aligned with the status. The main risk is the following sequence:

  1. Alice mark the test as failed
  2. Edit the comment to inform about the error she got and add evidences about the failure
  3. Bob try to re-run the failed step but this time it works
  4. Bob mark the test as Passed but the comment was not edited
  5. Now the comment refers to an error (alice error) but the test actually passed => inconsistency

Acceptance criteria

In order to support the new use cases while limiting the risk of inconsistency:

  • As soon as a comment is saved, the comment box turns read only (grayed)
  • If someone wants to modify a comment, they must click on "Edit comment"
  • Saving the comment can be done with "Save comment" button
  • Changing status with comment section in edit mode saves the comment
  • If a comment is set and the status is something else than "Not run", then changing the status without changing the comment raises a warning:
    • With Alice and Bob example, at step 4, Bob's is told that he should look at the comment because it's likely to be outdated.
    • The warning is displayed only to the test executor and only when they change the status (pure front-end). If tester reloads the page for instance, the warning will be gone.

Business rules must be enforced in front-end, backend (API) and realtime.

For instance, for API/Backend:

  • Given Alice saves a comment on a test
  • When Bob loads this test
  • Then Bob see the comment box with Alice comment in read only

For instance for realtime:

  • Given Alice loads test exec "my fine test"
  • And Bob also loads test exec "my fine test"
  • When Alice save a comment on the test
  • Then Bob sees the saved comment, in read-only, without having to reload the page.

Realtime triggers synchronization when the comment is saved:

  • Either with "Save button"
  • Or with Change of status

The old display of comment (at top) is removed as it's now displayed at the bottom of the test.

Empty
Status
Empty
Done
Development
  • [ ] Does it involves User Interface? 
  • [ ] Are there any mockups?
  • [ ] Are permissions checked?
  • [ ] Does it need Javascript development?
  • [ ] Does it need a forge upgrade bucket?
  • [ ] Does it need to execute things in system events?
  • [ ] Does it impact project creation (templates)?
  • [ ] Is it exploratory?
Empty
Details
#22226
Manuel Vacelet (vaceletm)
2021-09-15 16:20
2021-07-16 13:32
3728

References
Referencing story #22226

Git commit

tuleap/tuleap/stable

Move details modal in comment section e5c0169352
feat: Display comment in comment box in write mode 440778a490
Move status buttons under comment box 862661a251
Background of footer section is not white 5ea560a2e3
fix: update hover state of open modal button fdf42a1481
Add "Edit comment" button 5dff441a31
Display existing comment in comment box 47e793d899
Display existing comment in comment box 2e992535d7
fix: CKeditor dropdown was no longer shown abb5b6a2ae
refacto: deal with "CommentEditor" instead of "CommentContainer" 800d37897d
fix: Increase size of expand icon c057ec03ad
Do not edit comment when campaign is closed 5979854b4c
Can cancel the modification of the comment fcc740ab13
feat: Display more than one line in comment preview 3e5e5aa28b
Display warning when only status is updated 97e3062a93
fix: Comment buttons and small screens dd2bdde0e3
Do not edit comment when campaign must be reloaded 4b94d9ff0d
Not run button has no longer disabled color after clicking ae4a7bd2b5
feat: Dismissable warning message 49187ba95d
Comment should be updated automatically 1f506f32ac
CKeditor raises error in console in some cases 6d95642712
Move campaign progression next to campaign name ed585c535a
Enhance current test header design 7e87ec9c09
Enhance current test content design 59d7c9a6c9
Fix current test loader position and progression shadows 761009c604
Enhance current test footer design 09d70da3d0
Enhance current test list design f27e39e004
Small UI fixes 88546aff45
fix: js error when refreshing a test a624abc6d2
fix: Proportional progress bar of passed tests a15f194132
fix: Realtime issue when editing a comment in TTM 67a2517460

Follow-ups

User avatar

Remove the ACs related to multiple files as it got its own story #22576


  • Acceptance criteria
    Something went wrong, the follow up content couldn't be loaded
    Only formatting have been changed, you should switch to markup to see the changes
User avatar
  • Acceptance criteria
    Something went wrong, the follow up content couldn't be loaded
    Only formatting have been changed, you should switch to markup to see the changes
User avatar
  • I want to
    -edit test comments and attach files 
    +edit test execution comments 
  • Acceptance criteria
    Something went wrong, the follow up content couldn't be loaded
    Only formatting have been changed, you should switch to markup to see the changes
User avatar
Joris MASSON (jmasson)2021-07-27 12:16

Expand technical concerns section for file upload after investigation


  • Acceptance criteria
    Something went wrong, the follow up content couldn't be loaded
    Only formatting have been changed, you should switch to markup to see the changes
User avatar
  • Acceptance criteria
    Something went wrong, the follow up content couldn't be loaded
    Only formatting have been changed, you should switch to markup to see the changes
User avatar
  • I want to
    -attach files in the test execution comment box 
    +edit test comments and attach files 
  • Acceptance criteria
    Something went wrong, the follow up content couldn't be loaded
    Only formatting have been changed, you should switch to markup to see the changes
User avatar
  • Acceptance criteria
    Something went wrong, the follow up content couldn't be loaded
    Only formatting have been changed, you should switch to markup to see the changes