Skip to content

Commit

Permalink
Replace C-style array declaration with Java-style array declaration
Browse files Browse the repository at this point in the history
  • Loading branch information
basil committed Dec 17, 2024
1 parent c9b09ed commit 898e98d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/test/java/hudson/plugins/ec2/SlaveTemplateUnitTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ protected Object readResolve() {
Method updateRemoteTags = SlaveTemplate.class.getDeclaredMethod(
"updateRemoteTags", AmazonEC2.class, Collection.class, String.class, String[].class);
updateRemoteTags.setAccessible(true);
final Object params[] = {ec2, awsTags, "InvalidInstanceRequestID.NotFound", new String[] {instanceId}};
final Object[] params = {ec2, awsTags, "InvalidInstanceRequestID.NotFound", new String[] {instanceId}};
updateRemoteTags.invoke(orig, params);
assertEquals(0, handler.getRecords().size());
}
Expand Down Expand Up @@ -176,7 +176,7 @@ protected Object readResolve() {
Method updateRemoteTags = SlaveTemplate.class.getDeclaredMethod(
"updateRemoteTags", AmazonEC2.class, Collection.class, String.class, String[].class);
updateRemoteTags.setAccessible(true);
final Object params[] = {ec2, awsTags, "InvalidSpotInstanceRequestID.NotFound", new String[] {instanceId}};
final Object[] params = {ec2, awsTags, "InvalidSpotInstanceRequestID.NotFound", new String[] {instanceId}};
updateRemoteTags.invoke(orig, params);

assertEquals(5, handler.getRecords().size());
Expand Down

0 comments on commit 898e98d

Please sign in to comment.