This is an automated email from the ASF dual-hosted git repository.

chesnay pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/flink.git


The following commit(s) were added to refs/heads/master by this push:
     new d8c64a80848 [FLINK-32153][build] Limit powermock to core/runtime
d8c64a80848 is described below

commit d8c64a808484cab78c8bd7b74a287edf7d1f3b01
Author: Chesnay Schepler <ches...@apache.org>
AuthorDate: Wed May 24 10:56:52 2023 +0200

    [FLINK-32153][build] Limit powermock to core/runtime
---
 flink-core/pom.xml    | 12 +++++++++++
 flink-runtime/pom.xml | 19 +++++++++++++++++
 pom.xml               | 57 ++++++++++++++++++++++++---------------------------
 3 files changed, 58 insertions(+), 30 deletions(-)

diff --git a/flink-core/pom.xml b/flink-core/pom.xml
index cdbbd12ec2c..5ba7b349639 100644
--- a/flink-core/pom.xml
+++ b/flink-core/pom.xml
@@ -139,6 +139,18 @@ under the License.
                        <version>${project.version}</version>
                        <scope>test</scope>
                </dependency>
+
+               <dependency>
+                       <groupId>org.powermock</groupId>
+                       <artifactId>powermock-module-junit4</artifactId>
+                       <scope>test</scope>
+               </dependency>
+
+               <dependency>
+                       <groupId>org.powermock</groupId>
+                       <artifactId>powermock-api-mockito2</artifactId>
+                       <scope>test</scope>
+               </dependency>
        </dependencies>
 
        <build>
diff --git a/flink-runtime/pom.xml b/flink-runtime/pom.xml
index 09174f6f1c9..9790af3de9c 100644
--- a/flink-runtime/pom.xml
+++ b/flink-runtime/pom.xml
@@ -270,6 +270,25 @@ under the License.
                        <artifactId>oshi-core</artifactId>
                        <optional>true</optional>
                </dependency>
+
+               <dependency>
+                       <!-- This must appear before powermock on the 
classpath! -->
+                       <groupId>org.mockito</groupId>
+                       <artifactId>mockito-inline</artifactId>
+                       <scope>test</scope>
+               </dependency>
+
+               <dependency>
+                       <groupId>org.powermock</groupId>
+                       <artifactId>powermock-module-junit4</artifactId>
+                       <scope>test</scope>
+               </dependency>
+
+               <dependency>
+                       <groupId>org.powermock</groupId>
+                       <artifactId>powermock-api-mockito2</artifactId>
+                       <scope>test</scope>
+               </dependency>
        </dependencies>
 
        <build>
diff --git a/pom.xml b/pom.xml
index 5e1d8a33b06..8fbc45fa8d4 100644
--- a/pom.xml
+++ b/pom.xml
@@ -243,14 +243,6 @@ under the License.
                        <scope>test</scope>
                </dependency>
 
-               <dependency>
-                       <groupId>org.mockito</groupId>
-                       <artifactId>mockito-inline</artifactId>
-                       <version>${mockito.version}</version>
-                       <type>jar</type>
-                       <scope>test</scope>
-               </dependency>
-
                <dependency>
                        <groupId>org.mockito</groupId>
                        <artifactId>mockito-core</artifactId>
@@ -267,28 +259,6 @@ under the License.
                        <scope>test</scope>
                </dependency>
 
-               <dependency>
-                       <groupId>org.powermock</groupId>
-                       <artifactId>powermock-module-junit4</artifactId>
-                       <version>${powermock.version}</version>
-                       <type>jar</type>
-                       <scope>test</scope>
-               </dependency>
-
-               <dependency>
-                       <groupId>org.powermock</groupId>
-                       <artifactId>powermock-api-mockito2</artifactId>
-                       <version>${powermock.version}</version>
-                       <type>jar</type>
-                       <scope>test</scope>
-                       <exclusions>
-                               <exclusion>
-                                       <groupId>org.mockito</groupId>
-                                       <artifactId>mockito-core</artifactId>
-                               </exclusion>
-                       </exclusions>
-               </dependency>
-
                <dependency>
                        <groupId>org.hamcrest</groupId>
                        <artifactId>hamcrest-all</artifactId>
@@ -936,6 +906,33 @@ under the License.
                                <scope>test</scope>
                        </dependency>
 
+                       <dependency>
+                               <groupId>org.mockito</groupId>
+                               <artifactId>mockito-inline</artifactId>
+                               <version>${mockito.version}</version>
+                               <scope>test</scope>
+                       </dependency>
+
+                       <dependency>
+                               <groupId>org.powermock</groupId>
+                               <artifactId>powermock-module-junit4</artifactId>
+                               <version>${powermock.version}</version>
+                               <scope>test</scope>
+                       </dependency>
+
+                       <dependency>
+                               <groupId>org.powermock</groupId>
+                               <artifactId>powermock-api-mockito2</artifactId>
+                               <version>${powermock.version}</version>
+                               <scope>test</scope>
+                               <exclusions>
+                                       <exclusion>
+                                               <groupId>org.mockito</groupId>
+                                               
<artifactId>mockito-core</artifactId>
+                                       </exclusion>
+                               </exclusions>
+                       </dependency>
+
                </dependencies>
        </dependencyManagement>
 

Reply via email to