@Override
    public SortedMap<Integer, R> headMap(Integer toKey) {
        return subMap(Integer.MAX_VALUE, toKey);
    }
@Issue("JENKINS-26690")
    @Test public void headMap() {
        assertEquals("[]", a.headMap(Integer.MAX_VALUE).keySet().toString());
        assertEquals("[]", a.headMap(6).keySet().toString());
        assertEquals("[]", a.headMap(5).keySet().toString());
        assertEquals("[5]", a.headMap(4).keySet().toString());
        assertEquals("[5]", a.headMap(3).keySet().toString());
        assertEquals("[5, 3]", a.headMap(2).keySet().toString());
        assertEquals("[5, 3]", a.headMap(1).keySet().toString());
        assertEquals("[5, 3, 1]", a.headMap(0).keySet().toString());
        assertEquals("[5, 3, 1]", a.headMap(-1).keySet().toString());
        assertEquals("[5, 3, 1]", a.headMap(-2).keySet().toString()); // this failed
        assertEquals("[5, 3, 1]", a.headMap(Integer.MIN_VALUE).keySet().toString());
    }