Skip to main content

Spec file and folder status

A project typically has more spec files than you can keep open. The plugin can put each file's last result onto its icon in the Project tool window, and summarise a folder's contents on the folder itself, so you can see where the suite stands from the tree alone.

Both come from the same execution results, and both are opt-in and independent of each other: icons on the spec files, chevrons on the folders that hold them.

Spec file icons

Turn on Reflect execution status in spec file icons in the Project view, under Settings → Tools → SpecBinder → Execution results, and each spec file's icon shows how its last run went:

IconResult
<spec file icon in blue and teal>Blue and tealEvery scenario passed
<spec file icon in red>RedAt least one scenario failed
<spec file icon in amber>AmberNot run yet, or changed since the last run
<spec file icon in grey>GreyNo generated test class exists for this spec file

A scenario counts as not executed if you added it or changed it. One that aborted counts as not executed too, rather than as failed. A real failure outranks both.

<The Project tool window with spec files in three states — passed, failed and not executed — and a coloured chevron on a collapsed parent folder.>

Folder chevrons

Turn on Mark folders that contain spec files with a status chevron, the second option on the same Settings page, and each folder holding spec files gets a small coloured after its name. The colour is the worst result of any spec file beneath it, at any depth, so a single failure is visible on the collapsed parent without your opening a single folder.

ChevronMeaning
<folder name followed by a teal chevron>TealEvery spec below passed
<folder name followed by a red chevron>RedOne of them failed
<folder name followed by an amber chevron>AmberOne of them has not run yet
<folder name followed by a grey chevron>GreyOne of them has no generated test class

Red outranks amber, which outranks grey, which outranks teal. A folder with no spec files under it is left unmarked, and the folder's own icon and name are untouched — the chevron is added after them. If you want it more prominent, Use a heavier chevron glyph draws it as instead; the colours and their meanings do not change.

<A collapsed folder tree with coloured chevrons after the folder names, one red on a parent whose failing spec file is several levels down.>

When the icons change

Icons and chevrons are re-evaluated when you save an edited spec file, and when a new execution report lands after a run. Nothing changes while you type, so an unsaved edit never moves an icon.

Save a change to a scenario and its file drops to not executed; undo the change, save again, and it returns to passed. After a run the icons follow the new report, and a run that writes no report leaves them as they were.