Page MenuHomePhorge

The Celerity unit tests are not automatically run when touching whatever CSS or JS file
Open, HighPublic

Description

If you do:

$ arc unit --everything
...
   FAIL  PhabricatorCelerityTestCase::testCelerityMaps
Assertion failed, expected 'true' (at PhabricatorCelerityTestCase.php:32): When this test fails, it means the Celerity resource map is out of date. Run `bin/celerity map` to rebuild it.

ACTUAL VALUE
false
...

It can happen that it helps you in detecting that you need to run Celerity.

But, if you edit a CSS file, it can happen that this unit test is just skipped and marked as green light, like it happened here and here:

D25088: Workboard: in some cases, increase menu opacity (accessibility)

D25384: Fix icon background color when using Dark Mode

D25520: Show title entirely and cut of secondary information gracefully in typeahead results of main search

It says: Lint Not Applicable and Harbormaster completed the build:

B165: Diff 377

Saying "passed":

https://we.phorge.it/harbormaster/build/165/

What happens now

I touch CSS files.

So, it seems, arc diff calls arc unit, and then arc unit does not runs the unit tests related to Celerify.

What should happen instead

I touch CSS files.

So arc diff calls arc unit, and then arc unit runs the unit tests related to Celerify.

Note that this is the name of this specific unit test:

PhabricatorCelerityTestCase::testCelerityMaps

List of some known cases

Feel free to add a path here, if you toched that file, but the arc lint didn't say anything:

webroot/rsrc/css/phui/workboards/phui-workboard-color.css
webroot/rsrc/js/application/diffusion/DiffusionLocateFileSource.js
webroot/rsrc/css/application/base/main-menu-view.css

Event Timeline

valerio.bozzolan created this task.
valerio.bozzolan created this object in space S1 Public.
valerio.bozzolan renamed this task from The Celerity unit tests are not automatically run when touching a CSS file to The Celerity unit tests are not automatically run when touching whatever CSS or JS file.Jul 3 2023, 08:25
valerio.bozzolan updated the task description. (Show Details)
valerio.bozzolan updated the task description. (Show Details)
avivey raised the priority of this task from Normal to High.Jul 3 2023, 08:43