govuk_frontend_alpha icon indicating copy to clipboard operation
govuk_frontend_alpha copied to clipboard

Integration testing for compiled components (eg, ERB)

Open dsingleton opened this issue 8 years ago • 0 comments

Continuation from https://github.com/alphagov/govuk_frontend_alpha/pull/81

I tried to implement the same kind of test for ERB, but ran into issues with ruby/erb/bindings and how it should follow how rails interacts with ERB. It would be nice for the alpha - helping us catch where a transpile has introduced a bug, but required for a beta to avoid bugs in compiled templates not being caught in an automated way.

Ideally this would be an explicit rails integration test, not general ERB, as we're targetting a rails app with our gem/erb package. It's reliant on a lot of the rails helpers/scope, like escaping. Theres a question of how much we can imitate what rails does with ERB, to reduce testing complexity, vs how accurate the imitation is.

dsingleton avatar Dec 07 '16 11:12 dsingleton