The module has no automated tests at the moment, so CI only runs the linters. Adding a kernel test that covers the parts most likely to break:
- GlideStyle::render() attaches glidejs/glide and outputs the expected drupalSettings for a test view
- option normalization: focus_at cast to int (and "center" kept as is), autoplay falling back to 3000 when the speed is empty, disable_swipe / disable_drag / unlimited_touch resulting in false, peek as a number and as JSON
- the rendered markup contains one .glide__slide per row and the data attributes the JS relies on (view and display id), so we notice if the theme hook ever stops getting the rows
- the glidejs/glide library depends on core/drupalSettings, core/once and glidejs/glide_external, and the CDN URLs are pinned to a version
Needs a small test module with a view config that uses the glide style.
Comments
Comment #3
junkunczAI disclosure: the test was written with help from Claude. I ran it locally (4 tests, all passing) and checked that it actually fails when one of the fixes is reverted (removing core/once from the library made testLibraries fail).
Comment #4
junkunczComment #6
junkuncz