public boolean removeAction(@Nullable Action a) {
        if (a == null) {
            return false;
        }
        // CopyOnWriteArrayList does not support Iterator.remove, so need to do it this way:
        return getActions().removeAll(Set.of(a));
    }
@SuppressWarnings("deprecation")
    @Test
    public void removeAction() {
        CauseAction a1 = new CauseAction();
        ParametersAction a2 = new ParametersAction();
        thing.addAction(a1);
        thing.addAction(a2);
        assertEquals(Arrays.asList(a1, a2), thing.getActions());
        assertThat(thing.removeAction(a1), is(true));
        assertEquals(List.of(a2), thing.getActions());
        assertThat(thing.removeAction(a1), is(false));
        assertEquals(List.of(a2), thing.getActions());
        assertThat(thing.removeAction(null), is(false));
        assertEquals(List.of(a2), thing.getActions());
    }