docs: <test> takes no width or height

Merged
LA
3d ago
+13-11

The docs and the templates showed <test width="…" height="…">. The Editor and CLI reject both attributes, and the test runner never used them. As a result, kapa.ai recommended them, and agents copied them from AGENTS.md into the tests they write (for example <test width="800" height="480">), and those tests failed validation.

Changes

  • docs/syntax/testing.mdx: the example is a plain <test>. The page now says that <test> takes no attributes and that a test runs at the display size of the project.xml target.
  • templates/common/AGENTS.md: the component-test example is a plain <test>. The five project copies are synced.
  • templates/basic/tests/README.md: the example is a plain <test>, and the note about canvas size now says that a test has no size of its own.
  • templates/basic/tests/test_theme_toggle.xml: a plain <test>.

Why the attributes go

  • The released Editor/CLI (2.1.x) already reject width and height on <test>. staging briefly accepted them, and that is reverted in the Editor PR linked below.
  • lv_xml's test runner ignores the attributes of the <test> element.
  • The Editor and CLI size a test by the display of the target in project.xml.

Editor change: https://github.com/lvgl-private/editor/pull/1718

šŸ¤– Generated with Claude Code