Blob Blame History Raw
From 613f27fe7ff4a89c21689a16f6f6b9b3e0b7c347 Mon Sep 17 00:00:00 2001
From: Marian Koncek <mkoncek@redhat.com>
Date: Thu, 29 Aug 2019 15:04:46 +0200
Subject: [PATCH] Port to hamcrest 2.1

---
 .../shared/utils/reflection/ReflectorTest.java     | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/src/test/java/org/apache/maven/shared/utils/reflection/ReflectorTest.java b/src/test/java/org/apache/maven/shared/utils/reflection/ReflectorTest.java
index 0088361..09f6048 100644
--- a/src/test/java/org/apache/maven/shared/utils/reflection/ReflectorTest.java
+++ b/src/test/java/org/apache/maven/shared/utils/reflection/ReflectorTest.java
@@ -50,7 +50,7 @@ public class ReflectorTest
     public void newInstanceClassNull()
         throws Exception
     {
-        assertThat( reflector.newInstance( Object.class, null ), is( Object.class ) );
+        assertThat( reflector.newInstance( Object.class, null ), isA( Object.class ) );
     }
 
     @Test( expected = NullPointerException.class )
@@ -64,7 +64,7 @@ public class ReflectorTest
     public void newInstanceClassEmptyArray()
         throws Exception
     {
-        assertThat( reflector.newInstance( Object.class, new Object[0] ), is( Object.class ) );
+        assertThat( reflector.newInstance( Object.class, new Object[0] ), isA( Object.class ) );
     }
 
     @Test( expected = ReflectorException.class )
@@ -156,7 +156,7 @@ public class ReflectorTest
     public void getSingletonClassNull()
         throws Exception
     {
-        assertThat( reflector.getSingleton( (Class<?>)Object.class, (Object)null ), is( Object.class ) );
+        assertThat( reflector.getSingleton( (Class<?>)Object.class, (Object)null ), isA( Object.class ) );
     }
 
     @Test( expected = NullPointerException.class )
@@ -170,7 +170,7 @@ public class ReflectorTest
     public void getSingletonClassEmptyArray()
         throws Exception
     {
-        assertThat( reflector.getSingleton( Object.class, new Object[0] ), is( Object.class ) );
+        assertThat( reflector.getSingleton( Object.class, new Object[0] ), isA( Object.class ) );
     }
 
     @Test( expected = ReflectorException.class )
@@ -787,7 +787,7 @@ public class ReflectorTest
     public void invokeStaticClassNullNull()
         throws Exception
     {
-        assertThat( reflector.invokeStatic( Object.class, (String)null, (Object)null ), is( Object.class ) );
+        assertThat( reflector.invokeStatic( Object.class, (String)null, (Object)null ), isA( Object.class ) );
     }
 
     @Test( expected = NullPointerException.class )
@@ -801,7 +801,7 @@ public class ReflectorTest
     public void invokeStaticClassNullEmptyArray()
         throws Exception
     {
-        assertThat( reflector.invokeStatic( Object.class, null, new Object[0] ), is( Object.class ) );
+        assertThat( reflector.invokeStatic( Object.class, null, new Object[0] ), isA( Object.class ) );
     }
 
     @Test( expected = NullPointerException.class )
@@ -829,7 +829,7 @@ public class ReflectorTest
     public void invokeStaticClassEmptyEmptyArray()
         throws Exception
     {
-        assertThat( reflector.invokeStatic( Object.class, "", new Object[0] ), is( Object.class ) );
+        assertThat( reflector.invokeStatic( Object.class, "", new Object[0] ), isA( Object.class ) );
     }
 
     @Test( expected = IllegalArgumentException.class )
-- 
2.21.0