Markdown OKF-Schema Studio

Use case StRS-MDOKFSTUDIO-PALETTE-018

A writer pastes screenshots and rich text safely as Markdown

As a writer, I paste a screenshot and it becomes a picture of the document without any dialog, and I copy from a web page, a word processor or an editor and the headings, lists, links and tables arrive as Markdown in my block, with no script or tracking content that a later reader could be exposed to.

Use case diagram

How it is split

This use case (StRS) is reached by 2 paths, one per coloured line. A path goes from one situation (circle) to the next; each step (pill) is a behaviour (SwRS) with its own tests. Where paths meet, they share the circle or the step.

path 1: Paste a screenshot path 2: Paste rich text, starts at 2 other outcomeone dot = one scenario checked: nominal boundary refusal
SwRS-MDOKFSTUDIO-PALETTE-203: A pasted image is sent to the host and its name inserted on its own paragraphSwRS-MDOKFSTUDIO-PALETTE-2033 teststhe writer pastes a clipboard thatholds only an image and the pagesends it to the hostSwRS-MDOKFSTUDIO-PALETTE-196: The host saves a pasted image next to the document under a name it choosesSwRS-MDOKFSTUDIO-PALETTE-1966 teststhe host saves the image in thefolder of the document under aname it choosesSwRS-MDOKFSTUDIO-PALETTE-203: A pasted image is sent to the host and its name inserted on its own paragraphSwRS-MDOKFSTUDIO-PALETTE-2033 testsits reference is inserted as aparagraph of its ownSwRS-MDOKFSTUDIO-PALETTE-213: Pasted rich text is converted by the host and replaces the selection in one stepSwRS-MDOKFSTUDIO-PALETTE-2134 teststhe writer pastes text/html andthe host converts it to MarkdownSwRS-MDOKFSTUDIO-PALETTE-217: Pasted HTML becomes the matching MarkdownSwRS-MDOKFSTUDIO-PALETTE-2174 testseach known element is written asits MarkdownSwRS-MDOKFSTUDIO-PALETTE-203: A pasted image is sent to the host and its name inserted on its own paragraphSwRS-MDOKFSTUDIO-PALETTE-2033 teststhe image cannot be read orthe host refuses itSwRS-MDOKFSTUDIO-PALETTE-213: Pasted rich text is converted by the host and replaces the selection in one stepSwRS-MDOKFSTUDIO-PALETTE-2134 teststhe conversion failsSwRS-MDOKFSTUDIO-PALETTE-196: The host saves a pasted image next to the document under a name it choosesSwRS-MDOKFSTUDIO-PALETTE-1966 testsa check failsSwRS-MDOKFSTUDIO-PALETTE-229: Pasted HTML never brings active contentSwRS-MDOKFSTUDIO-PALETTE-2292 testsan unsafe address keeps only the textA block text box is open in edit mode (paths 1, 2)A block text box is openin edit mode2The host receives the imageThe host receives theimageThe image is saved next to the documentThe image is saved nextto the documentAn image reference stands as a paragraph of its ownAn image referencestands as a paragraph ofits ownThe host converts the HTMLThe host converts theHTMLThe selection is replaced by the converted MarkdownThe selection isreplaced by theconverted Markdown

This map has 282 different ways through it in 8 steps or fewer. Instead of testing each one end to end, the 5 behaviours on the map are tested one by one, with 29 scenarios.

Behaviours of this use case

SwRS-MDOKFSTUDIO-PALETTE-004Files dropped from the Explorer become links or images at the drop point not on the map5 testsSwRS-MDOKFSTUDIO-PALETTE-196The host saves a pasted image next to the document under a name it chooses 6 testsSwRS-MDOKFSTUDIO-PALETTE-203A pasted image is sent to the host and its name inserted on its own paragraph 3 testsSwRS-MDOKFSTUDIO-PALETTE-213Pasted rich text is converted by the host and replaces the selection in one step 4 testsSwRS-MDOKFSTUDIO-PALETTE-217Pasted HTML becomes the matching Markdown 4 testsSwRS-MDOKFSTUDIO-PALETTE-229Pasted HTML never brings active content 2 testsSwRS-MDOKFSTUDIO-PALETTE-264A pasted URL becomes a link, an autolink or an image in the block text box not on the map3 testsSwRS-MDOKFSTUDIO-TRUST-005The host handles the page messages of every preview, whatever the trust not on the map17 tests