- Issue created by @acbramley
- Merge request !11716Issue #3517023: Convert ckEditor5CodeSyntaxTest to WebDriver test → (Open) created by acbramley
- 🇦🇺Australia acbramley
So this one is quite easy to do in PHP, except that I can't figure out how to actually type in the editor which we need to prove that adding the code block adds the specific class/markup. Without typing anything, CKE returns no data.
I need to move on for today so have pushed what I've got so far.
- 🇦🇺Australia mstrelan
Honestly I don't know why we need to be testing the behaviour of the codeblock plugin. This is provided by CKE5 core and is thoroughly tested there. We should only be testing that we can configure the languages, and that the languages get passed to the plugin. I'd argue we don't need a JS test at all for this, but I guess a basic smoke test that the plugin is loading and the configured languages are available would be reasonable.
- 🇦🇺Australia acbramley
Absolutely agree with #4, I was actually trying to find which part of drupal was adding those tags we're testing in the nightwatch test. Seeing as it's the CKE5 plugin itself, we don't need the drama of testing it ourselves.
I've also added return types to 4 functions in CKEditor5TestTrait that were flagging new violations in the new test class. This means we can remove 240 lines from the baseline.