### Question:
BuilderContext { public final boolean checkExec(String command) { return execExceptions.contains(command); } private  BuilderContext(Logger log, PathNormalizer normalizer, String id, PathMatcher readMatcher,
      PathMatcher writeMatcher, PathMatcher tempMatcher, MessageCollector messages,
      Collection<String> execExceptions, boolean networkAccessAllowed,
      Collection<String> readExceptions, Collection<String> writeExceptions,
      PathMatcher readAndTrackExceptionsMatcher, InprogressStateWriter inprogressWriter,
      BuilderWorkspace workspace); void enter(); void leave(); static Builder builder(Logger log, String id, Path sessionBasedir,
      MessageCollector messages, BuilderWorkspace workspace); @Override String toString(); final boolean checkRead(String file); final boolean checkAndRecordWrite(String file); final boolean checkExec(String command); final boolean checkSockets(); boolean checkAndRecordProperty(String action, String name); boolean addViolation(EnforcerViolation violation); Set<EnforcerViolation> getViolations(); Collection<String> getWrittenFiles(); Collection<String> getTemporaryFiles(); Collection<String> getReadProperties(); String getId(); MessageCollector getMessages(); boolean wasWhitelistedException(String file); static Messages MESSAGES; }### Answer:
@Test public void testExec() throws Exception { BuilderContext testee = newBuilder() .addExecExceptions(Arrays.asList("git")).build(); assertTrue(testee.checkExec("git")); }