Detecting performance issues in software systems is desirable and sometimes critical. In this thesis, a new tool is presented for the purpose of testing performance at a smaller scale. This tool, JFRNG, is implemented as an extension to the Java testing framework TestNG with the purpose of allowing developers to test the performance of Java code in unit and integration tests. The thesis also contains a study of the current methods and approaches to automating the process of detecting performance issues. An evaluation of JFRNG is performed both in terms of performance and usability, where the tool is compared to JfrUnit, a similar tool that targets the JUnit framework. A usability survey took place during the usability evaluation where prof...