Page MenuHomePhabricator

Investigation: Write visual editor debug tool to produce Converter test cases
Closed, ResolvedPublic

Description

Background:

  • Visual editor converter tests working on the border between VE and Parsoid are notoriously difficult to write, requiring several separate, but coordinated, complex data structures to be filled out by hand. Although we've documented the crude process, it's still a chore.
  • Visual editor already includes a powerful debug toolbar which includes many tools for introspecting the document being edited and VE internal data structures.

If it were possible to automate the creation of test cases given a real document and any in-progress edits (called "transactions" in VE), this would be helpful to developers. The debug tooling within VE could be a great fit for this exact task.

Event Timeline

awight renamed this task from Investigation: Write visual editor debug tool to produce test cases to Investigation: Write visual editor debug tool to produce converter test cases.Jul 24 2025, 3:47 AM
awight updated the task description. (Show Details)

Change #1172159 had a related patch set uploaded (by Awight; author: Awight):

[VisualEditor/VisualEditor@master] [WIP] Debug tool to build domToData test cases

https://gerrit.wikimedia.org/r/1172159

Change #1174452 had a related patch set uploaded (by Awight; author: Awight):

[mediawiki/extensions/Cite@master] Regenerate test: Deletion of main ref does not orphan subref

https://gerrit.wikimedia.org/r/1174452

awight renamed this task from Investigation: Write visual editor debug tool to produce converter test cases to Investigation: Write visual editor debug tool to produce Converter test cases.Aug 6 2025, 3:25 PM

Change #1180574 had a related patch set uploaded (by Awight; author: Awight):

[VisualEditor/VisualEditor@master] [WIP] Accept data-only formats for converter tests

https://gerrit.wikimedia.org/r/1180574

Change #1180575 had a related patch set uploaded (by Awight; author: Awight):

[VisualEditor/VisualEditor@master] [WIP] Try rewriting debugging tool as pure data

https://gerrit.wikimedia.org/r/1180575

Change #1238737 had a related patch set uploaded (by WMDE-Fisch; author: WMDE-Fisch):

[VisualEditor/VisualEditor@master] Add originalHtml to ve.init.Target

https://gerrit.wikimedia.org/r/1238737

Change #1238737 abandoned by Awight:

[VisualEditor/VisualEditor@master] Add originalHtml to ve.init.Target

Reason:

Already done!

https://gerrit.wikimedia.org/r/1238737

Change #1172159 merged by jenkins-bot:

[VisualEditor/VisualEditor@master] Debugging tool to build domToData test cases

https://gerrit.wikimedia.org/r/1172159

Change #1174452 abandoned by WMDE-Fisch:

[mediawiki/extensions/Cite@master] Regenerate test: Deletion of main ref does not orphan subref

Reason:

Cleaning up, patch should be deprecated by now.

https://gerrit.wikimedia.org/r/1174452

@awight maybe we close this ticket and abandon leftover patches for now? 🤔

awight claimed this task.

Great! We have some more fine-tuning to make the output test fully usable, but +1 to doing it in new tasks.

Change #1259728 had a related patch set uploaded (by Awight; author: Awight):

[VisualEditor/VisualEditor@master] Select appropriate platform as dummy parent

https://gerrit.wikimedia.org/r/1259728

Change #1259907 had a related patch set uploaded (by Awight; author: Awight):

[VisualEditor/VisualEditor@master] Debug tool fetches originalHtml independent of platform

https://gerrit.wikimedia.org/r/1259907

Change #1259728 merged by jenkins-bot:

[VisualEditor/VisualEditor@master] Select appropriate platform as dummy parent

https://gerrit.wikimedia.org/r/1259728

Change #1259907 merged by jenkins-bot:

[VisualEditor/VisualEditor@master] Debug tool fetches originalHtml independent of platform

https://gerrit.wikimedia.org/r/1259907

Change #1259990 had a related patch set uploaded (by Esanders; author: Esanders):

[mediawiki/extensions/VisualEditor@master] Update VE core submodule to master (b92b418e4)

https://gerrit.wikimedia.org/r/1259990

Change #1259990 merged by jenkins-bot:

[mediawiki/extensions/VisualEditor@master] Update VE core submodule to master (b92b418e4)

https://gerrit.wikimedia.org/r/1259990