@@ -0,0 +1,1812 @@
+package hudson.plugins.git;%0A%0Aimport hudson.security.csrf.CrumbFilter;%0A%0Aimport org.junit.Before;%0Aimport org.junit.Rule;%0Aimport org.junit.Test;%0A%0Aimport javax.servlet.FilterChain;%0Aimport javax.servlet.http.HttpServletRequest;%0Aimport javax.servlet.http.HttpServletResponse;%0A%0Aimport java.util.Collections;%0A%0Aimport static org.mockito.Matchers.*;%0Aimport static org.mockito.Mockito.mock;%0Aimport static org.mockito.Mockito.never;%0Aimport static org.mockito.Mockito.times;%0Aimport static org.mockito.Mockito.verify;%0Aimport static org.mockito.Mockito.when;%0A%0Aimport org.jvnet.hudson.test.JenkinsRule;%0A%0Apublic class GitStatusCrumbExclusionTest %7B%0A%0A    @Rule%0A    public JenkinsRule r = new JenkinsRule();%0A%0A    private CrumbFilter filter;%0A    private HttpServletRequest req;%0A    private HttpServletResponse resp;%0A    private FilterChain chain;%0A%0A    @Before%0A    public void before() %7B%0A        filter = new CrumbFilter();%0A        req = mock(HttpServletRequest.class);%0A        resp = mock(HttpServletResponse.class);%0A        chain = mock(FilterChain.class);%0A    %7D%0A%0A    @Test%0A    public void testNotifyCommit() throws Exception %7B%0A        when(req.getPathInfo()).thenReturn(%22/git/notifyCommit%22);%0A        when(req.getMethod()).thenReturn(%22POST%22);%0A        when(req.getParameterNames()).thenReturn(Collections.%3CString%3EemptyEnumeration());%0A        filter.doFilter(req, resp, chain);%0A        verify(resp, never()).sendError(anyInt(), anyString());%0A    %7D%0A%0A    @Test%0A    public void testInvalidPath() throws Exception %7B%0A        when(req.getPathInfo()).thenReturn(%22/git/somethingElse%22);%0A        when(req.getMethod()).thenReturn(%22POST%22);%0A        when(req.getParameterNames()).thenReturn(Collections.%3CString%3EemptyEnumeration());%0A        filter.doFilter(req, resp, chain);%0A        verify(resp, times(1)).sendError(anyInt(), anyString());%0A    %7D%0A%7D%0A

Add test for crumb exclusion on /git/notifyCommit