public void reportMeasurement(final long durationNs)
    {
        if (!maxCycleTime.isClosed())
        {
            maxCycleTime.proposeMaxOrdered(durationNs);

            if (durationNs > cycleTimeThresholdNs)
            {
                cycleTimeThresholdExceededCount.incrementOrdered();
            }
        }
    }
@Test
    void reportMeasurementIsANoOpIfMaxCounterIsClosed()
    {
        final AtomicCounter maxCycleTime = mock(AtomicCounter.class);
        when(maxCycleTime.isClosed()).thenReturn(true);
        final AtomicCounter cycleTimeThresholdExceededCount = mock(AtomicCounter.class);
        final DutyCycleStallTracker dutyCycleStallTracker =
            new DutyCycleStallTracker(maxCycleTime, cycleTimeThresholdExceededCount, 1);

        dutyCycleStallTracker.reportMeasurement(555);

        verify(maxCycleTime).isClosed();
        verifyNoMoreInteractions(maxCycleTime);
        verifyNoInteractions(cycleTimeThresholdExceededCount);
    }