RFR (S): 6461635: [TESTBUG] BasicTests.sh test fails intermittently

Mattias Tobiasson mattias.tobiasson at oracle.com
Tue Dec 3 08:17:01 PST 2013


I have changed RunnerUtil.readFile() to this: 
try { 
byte[] bytes = Files.readAllBytes(file.toPath()); 
String content = new String(bytes); 
return content; 
} catch (IOException e) { 
e.printStackTrace(); 
throw e; 
} 

Can I set you as a reviewer of this patch as it is now? If so, I will ask Staffan to submit it. 
Thanks, 
Mattias 

----- Original Message ----- 
From: Alan.Bateman at oracle.com 
To: mattias.tobiasson at oracle.com 
Cc: serviceability-dev at openjdk.java.net 
Sent: Tuesday, December 3, 2013 2:25:17 PM GMT +01:00 Amsterdam / Berlin / Bern / Rome / Stockholm / Vienna 
Subject: Re: RFR (S): 6461635: [TESTBUG] BasicTests.sh test fails intermittently 


On 03/12/2013 11:53, Mattias Tobiasson wrote: 


Hi, 
I have updated the patch after the review. 

webrev: 
http://cr.openjdk.java.net/~ykantser/6461635/webrev.04/ 

Changes: 
1. Removed BasicTests.sh from ProblemList 
2. Use sun.tools.jar.Main to create jars. 
3. Application.java uses try-with-resources. 
4. Changed name of nested test class from Impl to TestMain. 
I looks at the updated webrev and the changes look good. 

One other opportunity for try-with-resources is in RunnerUtil.readFile, I didn't notice this in previous round. Better still would be use Files.readAllBytes to read the file in one call, or readAllLines if the file may be composed of several lines. This is just a minor point so no need to re-generate the webrev if you change anything here. 

I see Staffan is going to sponsor this for you. 

-Alan 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.openjdk.java.net/pipermail/serviceability-dev/attachments/20131203/16128680/attachment-0001.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 6461635.patch
Type: text/x-patch
Size: 66754 bytes
Desc: not available
Url : http://mail.openjdk.java.net/pipermail/serviceability-dev/attachments/20131203/16128680/6461635-0001.patch 


More information about the serviceability-dev mailing list