Skip to content

Commit 32ded03

Browse files
committed
Add tests for kapt gen folder
1 parent 8809ced commit 32ded03

1 file changed

Lines changed: 11 additions & 1 deletion

File tree

AndroidAnnotations/androidannotations-core/androidannotations/src/test/java/org/androidannotations/internal/helper/AndroidManifestFinderTest.java

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
/**
22
* Copyright (C) 2010-2016 eBusiness Information, Excilys Group
3+
* Copyright (C) 2016-2017 the AndroidAnnotations project
34
*
45
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
56
* use this file except in compliance with the License. You may obtain a copy of
@@ -33,6 +34,7 @@
3334
public class AndroidManifestFinderTest {
3435

3536
private static final String GRADLE_GEN_FOLDER = "build/generated/source/apt/debug";
37+
private static final String GRADLE_KOTLIN_GEN_FOLDER = "build/generated/source/kapt/debug";
3638

3739
private static final String MAVEN_GEN_FOLDER = "target/generated-sources/annotations";
3840

@@ -57,6 +59,10 @@ public static Iterable<Object[]> createTestData() {
5759
Object[] gradleManifestFoundInBundles = { GRADLE_GEN_FOLDER, "build/intermediates/bundles/debug", true };
5860
Object[] gradleManifestFoundInManifestsAapt = { GRADLE_GEN_FOLDER, "build/intermediates/manifests/aapt/debug", true };
5961

62+
Object[] gradleKotlinManifestFoundInManifests = { GRADLE_KOTLIN_GEN_FOLDER, "build/intermediates/manifests/full/debug", true };
63+
Object[] gradleKotlinManifestFoundInBundles = { GRADLE_KOTLIN_GEN_FOLDER, "build/intermediates/bundles/debug", true };
64+
Object[] gradleKotlinManifestFoundInManifestsAapt = { GRADLE_KOTLIN_GEN_FOLDER, "build/intermediates/manifests/aapt/debug", true };
65+
6066
Object[] mavenManifestFoundInTarget = { MAVEN_GEN_FOLDER, "target", true };
6167
Object[] mavenManifestFoundInSrc = { MAVEN_GEN_FOLDER, "src/main", true };
6268
Object[] mavenManifestFoundInRoot = { MAVEN_GEN_FOLDER, "", true };
@@ -65,15 +71,19 @@ public static Iterable<Object[]> createTestData() {
6571

6672
Object[] gradleManifestNotFound = { GRADLE_GEN_FOLDER, "", false };
6773

74+
Object[] gradleKotlinManifestNotFound = { GRADLE_KOTLIN_GEN_FOLDER, "", false };
75+
6876
Object[] mavenManifestNotFound = { MAVEN_GEN_FOLDER, "something", false };
6977

7078
Object[] eclipseManifestNotFound = { ECLIPSE_GEN_FOLDER, "something", false };
7179

7280
Object[] noGeneratedFolderFound = { "", "", false };
7381

7482
return Arrays.asList(gradleManifestFoundInManifests, gradleManifestFoundInBundles, gradleManifestFoundInManifestsAapt,
83+
gradleKotlinManifestFoundInManifests, gradleKotlinManifestFoundInBundles, gradleKotlinManifestFoundInManifestsAapt,
7584
mavenManifestFoundInTarget, mavenManifestFoundInSrc, mavenManifestFoundInRoot, eclipseManifestFound,
76-
gradleManifestNotFound, mavenManifestNotFound, eclipseManifestNotFound, noGeneratedFolderFound);
85+
gradleManifestNotFound, gradleKotlinManifestNotFound, mavenManifestNotFound, eclipseManifestNotFound,
86+
noGeneratedFolderFound);
7787
}
7888

7989
@Test

0 commit comments

Comments
 (0)