Skip to content

Commit ceb868f

Browse files
authored
Merge pull request #7 from pettermahlen/japicmp
add japicmp checks to integration-test module
2 parents 0599436 + a64c16a commit ceb868f

3 files changed

Lines changed: 116 additions & 2 deletions

File tree

dataenum-integration-test/pom.xml

Lines changed: 47 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,12 +42,57 @@
4242
<artifactId>fmt-maven-plugin</artifactId>
4343
</plugin>
4444
<plugin>
45-
<artifactId>maven-deploy-plugin</artifactId>
46-
<!-- don't deploy this artifact -->
45+
<groupId>com.github.siom79.japicmp</groupId>
46+
<artifactId>japicmp-maven-plugin</artifactId>
47+
<version>0.11.0</version>
4748
<configuration>
49+
<!-- enable once we've released 1.0.2 -->
4850
<skip>true</skip>
51+
<oldVersion>
52+
<dependency>
53+
<groupId>${project.groupId}</groupId>
54+
<artifactId>${project.artifactId}</artifactId>
55+
<version>1.0.2-SNAPSHOT</version>
56+
<type>jar</type>
57+
</dependency>
58+
</oldVersion>
59+
<newVersion>
60+
<file>
61+
<path>${project.build.directory}/${project.artifactId}-${project.version}.${project.packaging}</path>
62+
</file>
63+
</newVersion>
64+
<parameter>
65+
<breakBuildOnBinaryIncompatibleModifications>true</breakBuildOnBinaryIncompatibleModifications>
66+
<onlyBinaryIncompatible>true</onlyBinaryIncompatible>
67+
</parameter>
4968
</configuration>
69+
<executions>
70+
<execution>
71+
<phase>verify</phase>
72+
<goals>
73+
<goal>cmp</goal>
74+
</goals>
75+
</execution>
76+
</executions>
5077
</plugin>
5178
</plugins>
5279
</build>
80+
81+
<profiles>
82+
<profile>
83+
<id>coverage</id>
84+
<build>
85+
<plugins>
86+
<plugin>
87+
<groupId>org.jacoco</groupId>
88+
<artifactId>jacoco-maven-plugin</artifactId>
89+
<!-- no need to check coverage for this artifact -->
90+
<configuration>
91+
<skip>true</skip>
92+
</configuration>
93+
</plugin>
94+
</plugins>
95+
</build>
96+
</profile>
97+
</profiles>
5398
</project>
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
/*
2+
* -\-\-
3+
* DataEnum
4+
* --
5+
* Copyright (c) 2017 Spotify AB
6+
* --
7+
* Licensed under the Apache License, Version 2.0 (the "License");
8+
* you may not use this file except in compliance with the License.
9+
* You may obtain a copy of the License at
10+
*
11+
* http://www.apache.org/licenses/LICENSE-2.0
12+
*
13+
* Unless required by applicable law or agreed to in writing, software
14+
* distributed under the License is distributed on an "AS IS" BASIS,
15+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16+
* See the License for the specific language governing permissions and
17+
* limitations under the License.
18+
* -/-/-
19+
*/
20+
package com.spotify.dataenim.apicompat;
21+
22+
import com.spotify.dataenim.apicompat.subpackage.Other_dataenum;
23+
import com.spotify.dataenum.DataEnum;
24+
import com.spotify.dataenum.dataenum_case;
25+
import java.util.List;
26+
import java.util.Set;
27+
import javax.annotation.Nullable;
28+
29+
/** Starting point for dataenum API compatibility tests. */
30+
@DataEnum
31+
public interface MostThings_dataenum<T> {
32+
dataenum_case SimpleTypes(String s, Integer i, int unboxed);
33+
34+
dataenum_case Collections(Set<String> set, List<Boolean> list);
35+
36+
dataenum_case TypeParameter(T thing);
37+
38+
dataenum_case ReferencesOther(Other_dataenum other);
39+
40+
dataenum_case NullableParameter(@Nullable String maybeNull);
41+
}
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
/*
2+
* -\-\-
3+
* DataEnum
4+
* --
5+
* Copyright (c) 2017 Spotify AB
6+
* --
7+
* Licensed under the Apache License, Version 2.0 (the "License");
8+
* you may not use this file except in compliance with the License.
9+
* You may obtain a copy of the License at
10+
*
11+
* http://www.apache.org/licenses/LICENSE-2.0
12+
*
13+
* Unless required by applicable law or agreed to in writing, software
14+
* distributed under the License is distributed on an "AS IS" BASIS,
15+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16+
* See the License for the specific language governing permissions and
17+
* limitations under the License.
18+
* -/-/-
19+
*/
20+
package com.spotify.dataenim.apicompat.subpackage;
21+
22+
import com.spotify.dataenum.DataEnum;
23+
import com.spotify.dataenum.dataenum_case;
24+
25+
@DataEnum
26+
public interface Other_dataenum {
27+
dataenum_case Another();
28+
}

0 commit comments

Comments
 (0)