Behaviour SwRS-MDOKFSTUDIO-TOOLBAR-135
Export removes links to other files after a warning
When the exported page has relative, wiki or blocked links, the extension SHALL list them in a modal warning before the save dialog, keep the external and anchor links, write the other links as plain text, and stop the export when the writer cancels the warning.
Another outcome at step 1 of path 1 in StRS-MDOKFSTUDIO-TOOLBAR-014, in the state “A preview page is shown”.
Scenarios 3
The situations the tests check; open one to read it.
nominalExternal and anchor links stay
Givena page with an `https:` link, a `mailto:` link and an `#anchor` link
Whenthe page is exported
Theneach of the three keeps its `href`
nominalOther links become text after a warning
Givena page with the links `other.md`, `./sub/x.md#h`, `wiki:Page` and a blocked `file:` link
Whenthe page is exported
Thena modal warning lists the four targets before the save dialog, and after the writer accepts, the file shows their text with no `a` element
boundaryCancelling the warning
| Input | Outcome |
|---|---|
| The warning is cancelled | No save dialog opens and nothing is written |
| More than 20 removed links | The warning lists 20 and ends with "and N more" |
| No removed link | No warning is shown |