Release

Use Java Records

jSparrow Eclipse 4.5.0 & jSparrow Maven 3.12.0 We are happy to announce the jSparrow November release with one new refactoring rule! The 105th rule is motivated by Java Records. Use Java Records Since Java 16, record classes are a new kind of class in the Java language. Record classes help to model plain data aggregates Use Java Records

Replace Stream Collect by toList

jSparrow Eclipse 4.4.0 & jSparrow Maven 3.11.0 We are happy to announce the jSparrow October release with one new refactoring rule! The new rule makes use of a Stream API extension in Java 16. Replace Stream Collect by toList Java 16 iJava 16 introduced Stream.toList() as a shorthand method for converting a Stream into an unmodifiable List. Replace Stream Collect by toList

Use Switch Expression and more

jSparrow Eclipse 4.3.0 & jSparrow Maven 3.10.0 We are excited to announce that this autumn release brings three additional jSparrow rules! The new rules embrace some recent Java features like Switch Expressions and Text Blocks. Use Switch Expression This rule replaces the traditional switch statements with switch expressions which turned into a standard feature in Use Switch Expression and more

Use Pattern Matching for Instanceof

jSparrow 4.2.0This new jSparrow release supports upgrading to Java 16. New refactoring rule to your toolbox: Use Pattern Matching for Instanceof This rule replaces instanceof expressions by Pattern Matching for instanceof introduced in Java 16. It is common for Java programs to contain logic that combines type checking using instanceof with explicit type casting. Naturally, Use Pattern Matching for Instanceof

Replace JUnit 3 Test Cases

jSparrow 4.1.0 & jSparrow Maven Plugin 3.8.0This new jSparrow release brings more assistance on migrating JUnit 3 Tests. New key feature to your toolbox: Replace JUnit 3 Test Cases This rule migrates JUnit 3 tests to either JUnit JUpiter or JUnit 4 depending on the most up-to-date JUnit version available in the classpath. The following Replace JUnit 3 Test Cases

jSparrow Markers

jSparrow 4.0.0 & jSparrow Maven Plugin 3.7.0We are excited to announce the midsummer release comes with a major update to jSparrow 4.0.0. The key new feature in this release is the jSparrow Marker. Additionally, 3 more rules for refactoring JUnit tests are added to the jSparrow rule set, thus increasing the total number of refactoring jSparrow Markers

Replace JUnit 4 Assumptions with JUnit Jupiter

jSparrow 3.30.0 & jSparrow Maven Plugin 3.6.0New rule to your toolbox: Replace JUnit 4 Assumptions with JUnit Jupiter This new jSparrow release brings more assistance on transitioning to JUnit 5! This rule contributes to a stepwise transition to JUnit 5 by replacing the JUnit 4 assumption methods (namely, assumeTrue and assumeFalse) by the equivalent JUnit Replace JUnit 4 Assumptions with JUnit Jupiter

Replace JUnit assertThat with Hamcrest

New rule to your toolbox: Replace JUnit assertThat with Hamcrest This new jSparrow release eliminates some obstacles for migrating to JUnit 5! The JUnit Assert.assertThat method is deprecated. Its sole purpose is to forward the call to the MatcherAssert.assertThat defined in Hamcrest 1.3. Therefore, it is recommended to directly use the equivalent assertion defined in Replace JUnit assertThat with Hamcrest

Replace JUnit 4 Assertions with JUnit Jupiter

This new jSparrow release brings the final step on transitioning to JUnit 5! Replace JUnit 4 Assertions with JUnit Jupiter This rule contributes to a stepwise transition to JUnit 5 by replacing the JUnit 4 assertion methods by the equivalent JUnit 5 ones. For more details, visit our online documentation. Here is a short example, Replace JUnit 4 Assertions with JUnit Jupiter

Replace JUnit 4 Annotations with JUnit Jupiter

jSparrow 3.27.0 & jSparrow Maven Plugin 3.3.0 This new jSparrow release brings further assistance in migrating to JUnit 5! Replace JUnit 4 Annotations with JUnit Jupiter By replacing the JUnit 4 annotations with the corresponding Jupiter alternatives, this rule promotes an automated transition to JUnit Jupiter. For more details, visit our online documentation Here is Replace JUnit 4 Annotations with JUnit Jupiter

Replace JUnit Timeout Annotation Property with assertTimeout

jSparrow 3.26.0 & jSparrow Maven Plugin 3.2.0 Replace JUnit Timeout Annotation Property with assertTimeout jSparrow adds this new rule to help migrating to JUnit 5! The JUnit Jupiter API provides timeout assertions, i.e., assertions that make sure an executable completes before a timeout is exceeded.In JUnit 4 this is achieved by using annotation properties, e.g., Replace JUnit Timeout Annotation Property with assertTimeout

Replace JUnit ExpectedException with assertThrows and More

jSparrow 3.24.0 & jSparrow Maven Plugin 3.1.0 Winter Solstice Release Three new refactoring rules The winter solstice jSparrow release adds 3 new refactoring rules and opens a new chapter in refactoring towards JUnit 5: Replace JUnit ExpectedException with assertThrows In JUnit 4.13, the ExpectedException.none() rule is deprecated. The recommended alternative is to use assertThrows(). This new jSparrow rule performs such a Replace JUnit ExpectedException with assertThrows and More

Major Maven Plugin Update

jSparrow 3.23.0 & jSparrow Maven Plugin 3.0.0 Major Maven Plugin Update & formatting features We are excited to announce the major update of jSparrow Maven Plugin 3.0.0. The new key feature in Maven is the jsparrow:report that makes jSparrow’s static analysis capabilities available to everyone. More features are added to support standard formatters and to specify the sources to refactor using glob expressions. Major Maven Plugin Update

Use Files.newBufferedWriter

jSparrow 3.22.0 & jSparrow Maven Plugin 2.19.0 released jSparrow introduces the new rule Use Files.newBufferedWriter for optimizing the I/O operations on text files! Use Files.newBufferedWriter This rule makes use of the Files.newBufferedWriter method for initializing BufferedWriter objects to write text files in an efficient manner. For instance, the following code: is refactored to: Find out more information in the Release Use Files.newBufferedWriter

Create Temp Files Using Java NIO and more

jSparrow 3.21.0 & jSparrow Maven Plugin 2.18.0 released The autumn jSparrow release brings improvements in performance, security, and I/O operations. Use Offset Based String Methods This rule avoids creating intermediate String instances by making use of the overloaded offset based methods in the String API. is refactored to: Create Temp Files Using Java NIO A suitable alternative for Create Temp Files Using Java NIO and more

Reuse Random Objects & Use SecureRandom

jSparrow 3.20.0 & jSparrow Maven Plugin 2.17.0 released The focus of the new rules for jSparrow’s 3.20.0 release is on securing random number generators. Reuse Random Objects This rule extracts reusable java.util.Random objects from local variables to class or instance fields. The goal is to improve the unpredictability of the generated values. Moreover, the rule reduces the Reuse Random Objects & Use SecureRandom

Use Parameterized LDAP Query

jSparrow 3.19.0 & jSparrow Maven Plugin 2.16.0 released jSparrow 3.19.0 continues the series of security rules concerning injection attacks. Use Parameterized LDAP Query Similar to SQL queries, the LDAP search filters are also vulnerable to injection attacks. This rule parameterizes all potential user supplied input that are concatenated into an LDAP search filter. For instance, the following Use Parameterized LDAP Query

15 automated Java rules free of charge!

jSparrow 3.0.0 has been released! The solstice release of jSparrow has arrived! jSparrow offers 53 rules for finding bugs and other code smells and it replaces them with clean and modern Java code. Additionally, jSparrow version 3.0.0 brings a new jSparrow Starter version! This version makes it possible to apply 15 rules free of charge! 15 automated Java rules free of charge!

6 New rules!

This release brings 6 new rules and a news dashboard has been added to jSparrow! The new rules include: Remove Unnecessary Thrown Exceptions on Method Signatures Remove Double Negations Remove Explicit Call To super() Remove Unnecessary Semicolons Use StringBuilder::append Use Guard Condition You can click on the names of the new rules to check the 6 New rules!

First stepping stone for jSparrow

First stepping stone for jSparrow The jSparrow Midsummer Release 2.0 was released today:www.jSparrow.eu In addition, jSparrow is listed on the Eclipse Marketplace! Thanks a lot to our dedicated team who all have done a great job! Everyone is fully committed to the idea, from initial research to the Midsummer release, so that today an innovative solution for automated First stepping stone for jSparrow