adoroszlai commented on code in PR #5556:
URL: https://github.com/apache/ozone/pull/5556#discussion_r1391446987
##########
hadoop-ozone/recon/src/test/java/org/apache/hadoop/ozone/recon/persistence/AbstractReconSqlDBTest.java:
##########
@@ -53,35 +52,28 @@
* to access the DAOs easily.
*/
public class AbstractReconSqlDBTest {
-
- @Rule
- public TemporaryFolder temporaryFolder = new TemporaryFolder();
+ private Path temporaryFolder;
private Injector injector;
private DSLContext dslContext;
private Provider<DataSourceConfiguration> configurationProvider;
public AbstractReconSqlDBTest() {
try {
- temporaryFolder.create();
+ temporaryFolder = Files.createTempDirectory("JunitConfig");
configurationProvider =
- new
DerbyDataSourceConfigurationProvider(temporaryFolder.newFolder());
+ new DerbyDataSourceConfigurationProvider(Files.createDirectory(
+ temporaryFolder.resolve("Config")).toFile());
} catch (IOException e) {
- Assert.fail();
+ Assertions.fail();
}
}
protected AbstractReconSqlDBTest(Provider<DataSourceConfiguration> provider)
{
- try {
- temporaryFolder.create();
configurationProvider = provider;
Review Comment:
```suggestion
configurationProvider = provider;
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]