The decisions the run screen makes, as functions with no DOM and no network.
Every one of these was a bug in production, and none of them was testable
where it lived.
They were expressions buried inside a Mithril component — !!this.run && !this.dismissed deciding whether to replace the entire page, a catch block
deciding whether a failed poll meant "stalled" or "keep watching", a ternary
deciding whether a card shows the button that starts an update. A decision
that can only be reached by rendering a component and driving a browser is a
decision nobody tests, and all four shipped broken.
Pulled out here they are ordinary functions. The components stay thin enough
that what is left in them is markup.
The decisions the run screen makes, as functions with no DOM and no network.
Every one of these was a bug in production, and none of them was testable where it lived.
They were expressions buried inside a Mithril component —
!!this.run && !this.dismisseddeciding whether to replace the entire page, acatchblock deciding whether a failed poll meant "stalled" or "keep watching", a ternary deciding whether a card shows the button that starts an update. A decision that can only be reached by rendering a component and driving a browser is a decision nobody tests, and all four shipped broken.Pulled out here they are ordinary functions. The components stay thin enough that what is left in them is markup.