|
| 1 | +<?xml version="1.0" encoding="UTF-8"?> |
| 2 | +<!-- |
| 3 | +Copyright 2026 Google LLC |
| 4 | +
|
| 5 | +Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | +you may not use this file except in compliance with the License. |
| 7 | +You may obtain a copy of the License at |
| 8 | +
|
| 9 | + http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | +
|
| 11 | +Unless required by applicable law or agreed to in writing, software |
| 12 | +distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | +See the License for the specific language governing permissions and |
| 15 | +limitations under the License. |
| 16 | +--> |
| 17 | +<project xmlns="http://maven.apache.org/POM/4.0.0" |
| 18 | + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| 19 | + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> |
| 20 | + <modelVersion>4.0.0</modelVersion> |
| 21 | + |
| 22 | + <groupId>com.google.cloud.bigtable.hbase.enforcer.it</groupId> |
| 23 | + <artifactId>verify-published-pom-deps-stripped</artifactId> |
| 24 | + <version>1.0-SNAPSHOT</version> |
| 25 | + |
| 26 | + <description> |
| 27 | + Reproduces MSHADE-419: the shaded jar is attached under a classifier, so the main artifact is |
| 28 | + the thin unshaded jar, yet the generated dependency-reduced pom still strips its compile deps. |
| 29 | + The check must fail rather than let such a pom be published. |
| 30 | + </description> |
| 31 | + |
| 32 | + <properties> |
| 33 | + <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> |
| 34 | + </properties> |
| 35 | + |
| 36 | + <build> |
| 37 | + <plugins> |
| 38 | + <plugin> |
| 39 | + <groupId>org.apache.maven.plugins</groupId> |
| 40 | + <artifactId>maven-shade-plugin</artifactId> |
| 41 | + <version>3.6.0</version> |
| 42 | + <executions> |
| 43 | + <execution> |
| 44 | + <phase>package</phase> |
| 45 | + <goals> |
| 46 | + <goal>shade</goal> |
| 47 | + </goals> |
| 48 | + <configuration> |
| 49 | + <shadedArtifactAttached>true</shadedArtifactAttached> |
| 50 | + <createDependencyReducedPom>true</createDependencyReducedPom> |
| 51 | + <filters> |
| 52 | + <filter> |
| 53 | + <artifact>*:*</artifact> |
| 54 | + <excludes> |
| 55 | + <exclude>META-INF/*.MF</exclude> |
| 56 | + </excludes> |
| 57 | + </filter> |
| 58 | + </filters> |
| 59 | + </configuration> |
| 60 | + </execution> |
| 61 | + </executions> |
| 62 | + </plugin> |
| 63 | + |
| 64 | + <plugin> |
| 65 | + <groupId>com.google.cloud.bigtable.test</groupId> |
| 66 | + <artifactId>bigtable-build-helper</artifactId> |
| 67 | + <version>2.20.2-SNAPSHOT</version> <!-- {x-version-update:bigtable-client-parent:current} --> |
| 68 | + <executions> |
| 69 | + <execution> |
| 70 | + <id>test</id> |
| 71 | + <goals> |
| 72 | + <goal>verify-published-pom-deps</goal> |
| 73 | + </goals> |
| 74 | + <configuration> |
| 75 | + <requiredDependencies> |
| 76 | + <requiredDependency>com.google.guava:guava</requiredDependency> |
| 77 | + </requiredDependencies> |
| 78 | + </configuration> |
| 79 | + </execution> |
| 80 | + </executions> |
| 81 | + </plugin> |
| 82 | + </plugins> |
| 83 | + </build> |
| 84 | + |
| 85 | + <!-- Do not upgrade these dependencies, they are only used as a test subject --> |
| 86 | + <dependencies> |
| 87 | + <dependency> |
| 88 | + <groupId>com.google.guava</groupId> |
| 89 | + <artifactId>guava</artifactId> |
| 90 | + <version>30.1-android</version> |
| 91 | + </dependency> |
| 92 | + </dependencies> |
| 93 | +</project> |
0 commit comments