In this release, we have added numerous enhancements, focusing our efforts on unit testing in the context of the following areas:
On the static analysis side of things, we’ve added support for the newest OWASP guidelines (2017), along with standard bug fixes and improvements there. We also improved performance and expanded platform support.
Read on to learn more about these enhancements and how to benefit from them!
As you build your testing pyramid, you need a solid foundation of unit tests, but as so many of you express, creating those unit tests can be troublesome and time consuming. As with previous versions of Jtest, the Unit Test Assistant continues its objective of making unit test creation easier for you. With 10.3.4, there are two new features that have been added to help with this:
Having trouble finding that one factory method in your code that you want to use to initialize some object? Or did you forget the right coding syntax to use to instantiate your factory object? With Jtest 10.3.4, you can now configure the Unit Test Assistant to use the factory methods that are available in your source code to further increase efficiency and productivity of the test creation process.
Easily tag and un-tag factory methods, and the Unit Test Assistant will auto-discover them and allow you to use these factory methods within your unit tests. Instantiate using factory in the Unit Test Assistant view. The action will show up when a relevant factory method is available for the selected type. If more than one factory method is available for a specific type, the Unit Test Assistant will prioritize factory methods whose return type is the closest match to the type of the variable being initialized. The Unit Test Assistant will also prefer factory methods in the same package or in the closest parent package.
Tired of creating Spring unit tests one file at a time? With Jtest 10.3.4, we’ve added support for creating unit tests for multiple Spring files, to help optimize the creation process. In the Unit Test Assistant view, you will now have a new action icon for “Add Spring test case(s).” Alternatively, you can right-click in the editor’s package explorer view and get a context menu to create unit tests that way.
Once you’ve started your unit test foundation, you need to scale it out to cover all your code. Trying to scale out Spring unit testing in the past was a bit of a pain point, but with new support for creating multiple Spring tests, you can now build out your Spring test suite simply and easily. The bulk creation of Spring unit tests allows you to quickly select a package or project of Spring classes and generate unit tests for those classes, giving you a quick way to scale out your testing practice. The Unit Test Assistant now gives you a jump start to your Spring testing so that you can spend more time adding the business logic that goes into the test.
In Jtest 10.3.3, the Unit Test Assistant view was the central view for seeing all your unit testing data and actions, which limited the ability to see different data at the same time. To improve viewability of the data and actions, we split the Unit Test Asssistant view into multiple views. The following views are now available in Jtest 10.3.4, allowing you to create and enhance your tests, as well as review test results:
For a quick way to set up these views, in 10.3.4, the Jtest perspective in Eclipse has been updated to launch all of these views for you, which we’ve arranged in a logical order so you can easily see what you need to see.
Although unit testing was the major area of focus for Jtest 10.3.4, we didn’t neglect the static analysis portion of the software. In this area, we made several bug fixes to the following code analysis rules:
With Jtest 10.3.4, we have also extended our support for the OWASP standard and added the new OWASP Top 10 2017 built-in test configuration. This includes rules that find issues identified in OWASP’s Top 10 standard, helping you beef up your application’s security.
For those wanting to speed up the performance of Jtest, we have added a new UI option to improve just that. Now Jtest can launch on IDE startup to speed up the first run analysis.
In Jtest 10.3.4, we continue to extend our reach by now supporting the following platforms, IDEs, and build systems:
More details regarding all these enhancements can be found in the release notes. If you are an existing customer, you can check out the Parasoft Customer Portal to get access to them and download the latest installers for the latest features. If you’re new to Parasoft, please request a demo and one of our solution experts will be happy to answer questions and give you a more detailed presentation. Happy Java testing!
Kapil is a Product Manager at Parasoft, focusing on Parasoft Jtest. Kapil held several technical positions ranging from software engineer to development lead, before moving into product management.