You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@felix.apache.org by pa...@apache.org on 2020/09/07 08:40:57 UTC
[felix-dev] branch master updated: Backport test for java7
This is an automated email from the ASF dual-hosted git repository.
pauls pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/felix-dev.git
The following commit(s) were added to refs/heads/master by this push:
new cf79e8c Backport test for java7
cf79e8c is described below
commit cf79e8c7ef71ef2f47f49d0830aa720a1c97561a
Author: Karl Pauls <kp...@adobe.com>
AuthorDate: Mon Sep 7 10:40:43 2020 +0200
Backport test for java7
---
.../java/org/apache/felix/framework/ResourceLoadingTest.java | 10 ++++------
1 file changed, 4 insertions(+), 6 deletions(-)
diff --git a/framework/src/test/java/org/apache/felix/framework/ResourceLoadingTest.java b/framework/src/test/java/org/apache/felix/framework/ResourceLoadingTest.java
index ddec326..dab3ecd 100644
--- a/framework/src/test/java/org/apache/felix/framework/ResourceLoadingTest.java
+++ b/framework/src/test/java/org/apache/felix/framework/ResourceLoadingTest.java
@@ -101,13 +101,11 @@ public class ResourceLoadingTest extends TestCase
assertNotNull(testBundle.getResource(name));
assertNotNull(testBundle.getEntry(name));
- try (BufferedReader reader = new BufferedReader(new InputStreamReader(testBundle.getResource(name).openStream()))) {
- assertEquals("This is a Test", reader.readLine());
- }
- try (BufferedReader reader = new BufferedReader(new InputStreamReader(testBundle.getEntry(name).openStream()))) {
- assertEquals("This is a Test", reader.readLine());
- }
+ BufferedReader reader = new BufferedReader(new InputStreamReader(testBundle.getResource(name).openStream()));
+ assertEquals("This is a Test", reader.readLine());
+ reader = new BufferedReader(new InputStreamReader(testBundle.getEntry(name).openStream()));
+ assertEquals("This is a Test", reader.readLine());
}
private static void deleteDir(File root) throws IOException