@@ -0,0 +1,3135 @@
+/*%0A * This file is part of FastClasspathScanner.%0A * %0A * Author: Luke Hutchison%0A * %0A * Hosted at: https://github.com/lukehutch/fast-classpath-scanner%0A * %0A * --%0A *%0A * The MIT License (MIT)%0A *%0A * Copyright (c) 2016 Luke Hutchison%0A * %0A * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated%0A * documentation files (the %22Software%22), to deal in the Software without restriction, including without%0A * limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of%0A * the Software, and to permit persons to whom the Software is furnished to do so, subject to the following%0A * conditions:%0A * %0A * The above copyright notice and this permission notice shall be included in all copies or substantial%0A * portions of the Software.%0A * %0A * THE SOFTWARE IS PROVIDED %22AS IS%22, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT%0A * LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO%0A * EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN%0A * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE%0A * OR OTHER DEALINGS IN THE SOFTWARE.%0A */%0Apackage io.github.lukehutch.fastclasspathscanner.issues.issue102;%0A%0Aimport static org.assertj.core.api.Assertions.assertThat;%0A%0Aimport java.lang.reflect.Method;%0Aimport java.util.ArrayList;%0Aimport java.util.List;%0A%0Aimport org.junit.Test;%0A%0Aimport io.github.lukehutch.fastclasspathscanner.FastClasspathScanner;%0Aimport io.github.lukehutch.fastclasspathscanner.matchprocessor.ClassAnnotationMatchProcessor;%0Aimport io.github.lukehutch.fastclasspathscanner.matchprocessor.MethodAnnotationMatchProcessor;%0A%0A@Deprecated%0Apublic class Issue102Test %7B%0A    @Test%0A    public void deprecatedClass() %7B%0A        final List%3CString%3E matchedClassNames = new ArrayList%3C%3E();%0A        new FastClasspathScanner(Issue102Test.class.getPackage().getName())%0A                .matchClassesWithAnnotation(Deprecated.class, new ClassAnnotationMatchProcessor() %7B%0A                    @Override%0A                    public void processMatch(final Class%3C?%3E matchingClass) %7B%0A                        matchedClassNames.add(matchingClass.getName());%0A                    %7D%0A                %7D).scan();%0A        assertThat(matchedClassNames).containsOnly(Issue102Test.class.getName());%0A    %7D%0A%0A    @Test%0A    public void deprecatedMethod() %7B%0A        final List%3CString%3E matchedClassNames = new ArrayList%3C%3E();%0A        new FastClasspathScanner(Issue102Test.class.getPackage().getName())%0A                .matchClassesWithMethodAnnotation(Deprecated.class, new MethodAnnotationMatchProcessor() %7B%0A                    @Override%0A                    public void processMatch(final Class%3C?%3E matchingClass, final Method matchingMethod) %7B%0A                        matchedClassNames.add(matchingClass.getName());%0A                    %7D%0A                %7D).scan();%0A        assertThat(matchedClassNames).containsOnly(Issue102Test.class.getName());%0A    %7D%0A%0A    @Deprecated%0A    public void myMethod() %7B%0A    %7D%0A%7D%0A

Test for #102