zooniverse / Panoptes-Front-End

Front end for zooniverse/Panoptes
https://www.zooniverse.org
Apache License 2.0
64 stars 75 forks source link

Pages Editor: implement Delete Page action #7046

Closed shaunanoordin closed 4 months ago

shaunanoordin commented 4 months ago

PR Overview

Part of: Pages Editor MVP project and FEM Lab super-project Follows #6991 Staging branch URL: https://pr-7046.pfe-preview.zooniverse.org/lab/1982/workflows/editor/3711?env=staging

This PR adds the ability to delete a Step/Page.

Other changes:

Notes:

Status

Ready for review!

coveralls commented 4 months ago

Coverage Status

coverage: 56.98%. remained the same when pulling 0257819d352cbd34a82f849575ecef05c70d654f on pages-editor-pt14 into 3c979c8d1048a210ce230726adaeda7cc9017c3c on master.

shaunanoordin commented 4 months ago

PR Update

shaunanoordin commented 4 months ago

I can't believe I forgot to add in a Testing section.

Testing

In this PR, we're testing the "Delete Pages" action. (Dev Reminder: pages == steps. "Page" is what the volunteer sees. "step" is what's in the code.)

Testing steps:

Basically, the big hidden rule that Expectations 1 to 3 attempts to codify is that, when you delete a Page and all its Tasks, then ALL SECONDARY REFERENCES to that Page and Task should ALSO be nuked, and the workflow should continue working as if they never existed.

Example: a 3 Page workflow created via Quick Setup. The first page (with T0) is a branching Page that points to the second page (with T1) and the third page (with T2).

image
shaunanoordin commented 4 months ago

Thanks Travis! 👍

Might be useful to create a document of interesting edge cases / concerns / outline of all useful tests to be written when this gets migrated to FEM.

Ooo good point, I'm going to need to bring up the idea of starting this doc, to Sam & Sean next Monday.