robbieaverill

i think if they work in react forms then it should be fine - elemental editor v4 is just a series of FormBuilderLoaders

robbieaverill

up until recently SapphireTest was always flushing in SS4 unit tests 😛

robbieaverill

https://github.com/silverstripe/silverstripe-framework/pull/8398 for reference

Show 1 attachment(s)
chillu

It's massively slowing down test execution,
particularly for rapid execution through test-driven-development (TDD)

Regression since 4.0.0-beta1, see https://github.com/silverstripe/silverstripe-framework/commit/3873e4ba008cfc2af7e26ca86665affc289cd677#diff-e2f3520673dab1cd0127a469fe3a2a29R925|3873e4b#diff-e2f3520673dab1cd0127a469fe3a2a29R925

It replaced prior behaviour which respected the flush parameter: https://github.com/silverstripe/silverstripe-framework/commit/3873e4ba008cfc2af7e26ca86665affc289cd677#diff-e2f3520673dab1cd0127a469fe3a2a29R925|3873e4b#diff-e2f3520673dab1cd0127a469fe3a2a29R925

You could argue this is an API change, but I think it's not going to affect anyone negatively in production. CI based tests are quite unlikely to change files or YAML config between test runs which would require a manifest rebuild. And developers executing tests should follow our existing documentation which always said to use flush between test runs when you change stuff.

Hide attachment content
robbieaverill

there's a sort of hack you can do by extending each page type with a test only class and hiding its ancestor e.g. class HiddenVirtualPage extends VirtualPage implements TestOnly { private static $hide_ancestor = VirtualPage::class; } (i think)

robbieaverill

If forking the module is the solution- that’s not optimal

robbieaverill

reminds me: take a look at admin/client/src/bundles/bundle.js