-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpom.xml
412 lines (407 loc) · 15.8 KB
/
pom.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
<?xml version="1.0" encoding="UTF-8"?>
<project
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.sonatype.oss</groupId>
<artifactId>oss-parent</artifactId>
<version>7</version>
</parent>
<groupId>com.google.truth</groupId>
<artifactId>truth-parent</artifactId>
<version>HEAD-SNAPSHOT</version>
<packaging>pom</packaging>
<name>Truth (Parent)</name>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<!-- Properties for plugins for which pluginManagement hasn't been working for us. -->
<maven-javadoc-plugin.version>3.2.0</maven-javadoc-plugin.version>
<maven-enforcer-plugin.version>3.0.0-M3</maven-enforcer-plugin.version>
<!-- Properties for multiple-artifact deps. -->
<auto-value.version>1.8.1</auto-value.version>
<!--
We have a separate property for each flavor of Guava (instead of a shared
version without the -android and -jre suffixes) because that lets
Dependabot update our Guava versions.
-->
<guava.android.version>30.1.1-android</guava.android.version>
<!--
Also, we have this comment in between the 2 flavors of Guava. That's
also to smooth the Dependabot update process: Dependabot generates a
separate PR for each flavor. Even if we approve both at the same
time, one gets submitted before the other, and
the other ends up with a merge conflict. That requires reapprovals.
-->
<guava.jre.version>30.1.1-jre</guava.jre.version>
<gwt.version>2.9.0</gwt.version>
<protobuf.version>3.15.8</protobuf.version>
<!-- Property for protobuf-lite protocArtifact, which isn't a "normal" Maven dep. -->
<!-- TODO(cpovirk): Use protobuf.version instead. But that requires finding the new way to request the Lite runtime. -->
<protobuf-lite.protoc.version>3.1.0</protobuf-lite.protoc.version>
<!-- Property for an extension, since Maven doesn't have extensionManagement. -->
<os-maven-plugin.version>1.7.0</os-maven-plugin.version>
</properties>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>com.google.truth</groupId>
<artifactId>truth</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>com.google.truth.extensions</groupId>
<artifactId>truth-liteproto-extension</artifactId>
<version>${project.version}</version>
</dependency>
<!--
We could add the other modules of Truth, but there's no need because no
modules depend on them yet.
-->
<dependency>
<!--
In addition to setting the version of Guava that's used when Truth
depends directly on com.google.common:guava, this section also
overrides the version that's pulled in transitively by guava-gwt
(which is a test-scope dependency of core Truth). The Guava APIs
"missing" in guava-android might cause us problems down the line if we
actually started to run nontrivial GWT tests; I'm not sure.
-->
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<version>${guava.android.version}</version>
</dependency>
<dependency>
<groupId>org.checkerframework</groupId>
<artifactId>checker-qual</artifactId>
<version>3.13.0</version>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.13.2</version>
</dependency>
<dependency>
<groupId>com.google.gwt</groupId>
<artifactId>gwt-user</artifactId>
<version>${gwt.version}</version>
</dependency>
<dependency>
<groupId>com.google.auto.value</groupId>
<artifactId>auto-value-annotations</artifactId>
<version>${auto-value.version}</version>
</dependency>
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava-gwt</artifactId>
<version>${guava.jre.version}</version>
</dependency>
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava-testlib</artifactId>
<version>${guava.android.version}</version>
</dependency>
<dependency>
<groupId>com.google.testing.compile</groupId>
<artifactId>compile-testing</artifactId>
<version>0.19</version>
<exclusions>
<exclusion>
<groupId>com.google.truth</groupId>
<artifactId>truth</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>com.google.errorprone</groupId>
<artifactId>error_prone_annotations</artifactId>
<version>2.6.0</version>
</dependency>
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-java</artifactId>
<version>${protobuf.version}</version>
</dependency>
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-lite</artifactId>
<version>3.0.1</version>
</dependency>
<dependency>
<groupId>com.google.re2j</groupId>
<artifactId>re2j</artifactId>
<version>1.6</version>
</dependency>
<dependency>
<groupId>org.ow2.asm</groupId>
<artifactId>asm</artifactId>
<version>9.1</version>
</dependency>
<dependency>
<groupId>com.google.jsinterop</groupId>
<artifactId>jsinterop-annotations</artifactId>
<version>2.0.0</version>
</dependency>
</dependencies>
</dependencyManagement>
<description>
Parent metadata for Truth, a Java assertion framework.
</description>
<modules>
<module>core</module>
<module>extensions</module>
</modules>
<prerequisites><maven>3.1.1</maven></prerequisites>
<developers>
<developer>
<id>cgruber</id>
<name>Christian Gruber</name>
<email>[email protected]</email>
<url>http://www.geekinasuit.com/</url>
<roles>
<role>creator</role>
<role>developer</role>
</roles>
<timezone>-8</timezone>
</developer>
<developer>
<id>kak</id>
<name>Kurt Alfred Kluever</name>
<roles>
<role>evolver</role>
<role>developer</role>
</roles>
<timezone>-5</timezone>
</developer>
<developer>
<id>dsaff</id>
<name>David Saff</name>
<roles>
<role>creator</role>
<role>developer</role>
</roles>
<timezone>-5</timezone>
</developer>
<developer>
<id>hagbard</id>
<name>David B</name>
<roles>
<role>creator</role>
<role>developer</role>
</roles>
<timezone>+2</timezone>
</developer>
</developers>
<url>http://github.com/google/truth</url>
<licenses>
<license>
<name>The Apache Software License, Version 2.0</name>
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
<distribution>repo</distribution>
</license>
</licenses>
<issueManagement>
<system>Github</system>
<url>https://github.com/google/truth/issues</url>
</issueManagement>
<ciManagement>
<system>Jenkins</system>
<url>https://travis-ci.org/google/truth</url>
</ciManagement>
<scm>
<connection>scm:git:[email protected]:google/truth.git</connection>
<url>scm:git:[email protected]:google/truth.git</url>
</scm>
<build>
<pluginManagement>
<plugins>
<!-- https://stackoverflow.com/a/51093732/28465 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-site-plugin</artifactId>
<version>3.9.1</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-project-info-reports-plugin</artifactId>
<version>3.1.2</version>
</plugin>
<plugin>
<artifactId>maven-javadoc-plugin</artifactId>
<version>${maven-javadoc-plugin.version}</version>
<configuration>
<additionalOptions>
<additionalOption>--frames</additionalOption>
<additionalOption>-Xdoclint:-html</additionalOption>
</additionalOptions>
<additionalJOptions>
<additionalJOption>--no-module-directories</additionalJOption>
</additionalJOptions>
<doctitle>Truth ${project.version}</doctitle>
<windowtitle>Truth ${project.version}</windowtitle>
<quiet>true</quiet>
<notimestamp>true</notimestamp>
<encoding>UTF-8</encoding>
<docencoding>UTF-8</docencoding>
<charset>UTF-8</charset>
<overview>overview.html</overview>
<detectJavaApiLink>false</detectJavaApiLink>
<links>
<!-- TODO(cpovirk): Link to the version that we depend on? -->
<link>https://guava.dev/releases/snapshot-jre/api/docs</link>
<link>https://developers.google.com/protocol-buffers/docs/reference/java</link>
<link>https://junit.org/junit4/javadoc/latest/</link>
<link>https://docs.oracle.com/javase/7/docs/api/</link>
</links>
<source>8</source>
<sourceFileExcludes>
<sourceFileExclude>**/super/**/*.java</sourceFileExclude>
</sourceFileExcludes>
</configuration>
</plugin>
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<version>3.2.0</version> <!-- work around ubuntu bug -->
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>animal-sniffer-maven-plugin</artifactId>
<version>1.20</version>
<configuration>
<signature>
<groupId>org.codehaus.mojo.signature</groupId>
<artifactId>java16-sun</artifactId>
<version>1.10</version>
</signature>
</configuration>
<executions>
<execution>
<id>check-java-version-compatibility</id>
<phase>test</phase>
<goals>
<goal>check</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.8.1</version>
<configuration>
<source>1.7</source>
<target>1.7</target>
<testSource>1.8</testSource>
<testTarget>1.8</testTarget>
</configuration>
</plugin>
<plugin>
<artifactId>maven-source-plugin</artifactId>
<version>3.2.1</version>
</plugin>
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.22.2</version>
</plugin>
<plugin>
<artifactId>maven-enforcer-plugin</artifactId>
<version>${maven-enforcer-plugin.version}</version>
<executions>
<execution>
<id>enforce</id>
<configuration>
<rules>
<!--
Perhaps surprisingly, requireUpperBoundDeps catches problems
that dependencyConvergence does not: If we use
dependencyManagement to force Maven to use an *old* version
of a dependency, that will satisfy dependencyConvergence
(because the version is now consistent), but it will not
satisfy requireUpperBoundDeps, which apparently still sees
the original request for the newer version.
requireUpperBoundDeps's behavior is probably a good thing.
But, in what seems like a bug, dependencyConvergence catches
certain upper-bound problems that requireUpperBoundDeps does
not. To be clear, it's usually *not* a bug for
dependencyConvergence to give an error when
requireUpperBoundDeps does not: dependencyConvergence is in
some ways a stricter test than requireUpperBoundDeps. What
I'm seeing here is weirder: When I changed liteproto to
request checker-compat-qual 2.1.0 and
error_prone_annotations 2.0.9, both older versions than
those inherited through core Truth, dependencyConvergence
flagged both as expected, but requireUpperBoundDeps flagged
only error_prone_annotations. The reason for this may have
something to do with guava-25.1-android's dependency on the
even older checker-compat-qual 2.0.0: When I updated Truth
to depend on guava-26.0, which depends on
checker-compat-qual 2.5.3, then requireUpperBoundDeps
detected the problem.
I filed a bug against Maven:
https://issues.apache.org/jira/browse/MENFORCER-316
-->
<requireUpperBoundDeps>
<excludes>
<!-- We have some deps on guava-android and others on guava-jre. -->
<exclude>com.google.guava:guava</exclude>
</excludes>
</requireUpperBoundDeps>
<!--
This should be a no-op for us, since we try to list
everything in dependencyManagement. But it should at least
make sure that we do remember to put new deps into
dependencyManagement. It might also flag conflicts that
exist only in transitive dependencies. If that becomes too
much of a pain, we can back this check out.
-->
<dependencyConvergence />
<!--
Note that neither of these rules would catch a conflict
between, say, java8 and liteproto, since no Truth module
depends on both of those. If we wanted, we could create
such a module.
-->
</rules>
</configuration>
<goals>
<goal>enforce</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>gwt-maven-plugin</artifactId>
<version>${gwt.version}</version>
</plugin>
<plugin>
<groupId>org.xolstice.maven.plugins</groupId>
<artifactId>protobuf-maven-plugin</artifactId>
<version>0.6.1</version>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<!--
Force a version >2.7 for this parent project. If we use the current
default of 2.7, Maven ignores this parent project's configuration when
running maven-javadoc-plugin in children during releases.
-->
<plugin>
<artifactId>maven-javadoc-plugin</artifactId>
<version>${maven-javadoc-plugin.version}</version>
</plugin>
<!--
Similar. Without this, Maven tries to run maven-enforcer-plugin 1.0,
and it fails to construct an instance of the rule class, apparently
because of a mismatch between the new Maven APIs and the old Enforcer
APIs.
-->
<plugin>
<artifactId>maven-enforcer-plugin</artifactId>
<version>${maven-enforcer-plugin.version}</version>
</plugin>
</plugins>
</build>
</project>