node_modules exists when generating the CSS from the SCSS with yarn. And it contains invalid XML file. Which shouldn't be validated by Koha's test suite. ./node_modules/json-schema/draft-zyp-json-schema-03.xml ./node_modules/json-schema/draft-zyp-json-schema-04.xml
Created attachment 97825 [details] [review] Bug 24494: tests: 00-valid-xml.t shouldn't check node_modules == Test plan == - work with SCSS (just recompile it if you never did) - https://wiki.koha-community.org/wiki/Working_with_staff_client_SCSS - now you have a node_modules directory - prove -r t/00-valid-xml.t - it should fail on files in node_modules - apply this patch - prove -r t/00-valid-xml.t - it should work - sabotage a legitimate XML file, like etc/SIPconfig.xml - prove -r t/00-valid-xml.t - it should fail, good the test is still useful - undo the sabotage
Created attachment 98861 [details] [review] Bug 24494: tests: 00-valid-xml.t shouldn't check node_modules == Test plan == - work with SCSS (just recompile it if you never did) - https://wiki.koha-community.org/wiki/Working_with_staff_client_SCSS - now you have a node_modules directory - prove -r t/00-valid-xml.t - it should fail on files in node_modules - apply this patch - prove -r t/00-valid-xml.t - it should work - sabotage a legitimate XML file, like etc/SIPconfig.xml - prove -r t/00-valid-xml.t - it should fail, good the test is still useful - undo the sabotage Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Created attachment 98862 [details] [review] Bug 24494: Make the regex more exact Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Created attachment 99221 [details] [review] Bug 24494: tests: 00-valid-xml.t shouldn't check node_modules == Test plan == - work with SCSS (just recompile it if you never did) - https://wiki.koha-community.org/wiki/Working_with_staff_client_SCSS - now you have a node_modules directory - prove -r t/00-valid-xml.t - it should fail on files in node_modules - apply this patch - prove -r t/00-valid-xml.t - it should work - sabotage a legitimate XML file, like etc/SIPconfig.xml - prove -r t/00-valid-xml.t - it should fail, good the test is still useful - undo the sabotage Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Created attachment 99222 [details] [review] Bug 24494: Make the regex more exact Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Great work, been meaning to do this myself for ages.. Passed QA
Nice work everyone! Pushed to master for 20.05
Pushed to 19.11.x branch for 19.11.04
backported to 19.05.x for 19.05.09
*** Bug 22467 has been marked as a duplicate of this bug. ***