Conjunction implements Predicate { @Override public boolean at(short p) { return a.at(p) && b.at(p); } Conjunction(Predicate a, Predicate b); @Override boolean at(short p);  }
@Test public void testAt() { String[] before = { "......#", ".....#.", "..#...#", ".#.#...", "..#....", ".......", ".......", }; board.setUpProblem(before, BLACK); assertFalse(conjunction.at(at("g6"))); assertFalse(conjunction.at(at("c4"))); assertFalse(conjunction.at(at("a2"))); assertTrue(conjunction.at(at("d3"))); }