Looks ok to me.
-phil.
On 02/09/2016 03:46 PM, Jim Graham wrote:
Let me know if/when you have an updated webrev. It should be good to
go, but it couldn't hurt to publish one for the archives...
...jim
On 2/9/16 12:51 AM, Laurent Bourgès wrote:
Jim,
Here are my answers to your 2 questions:
2016-02-09 0:14 GMT+01:00 Jim Graham <james.gra...@oracle.com
<mailto:james.gra...@oracle.com>>:
In the test case, why are you using a log handler to check for a
particular exception? Shouldn't any exception logged be cause for a
test failure?
I already used that code in 1 other test: TextClipErrorTest. I agree it
can be simpler to report any exception like:
public void publish(LogRecord record) {
Throwable th = record.getThrown();
// detect any Throwable:
if (th != null) {
System.out.println("Test failed:\n" +
record.getMessage());
th.printStackTrace(System.out);
throw new RuntimeException("Test failed: ", th);
}
}
Is there a reason why you reversed the calculations for the slope at
line 374?
+ final double slope = (x1d - x2) / (y1d - y2);
I prefer this syntax as it is more explicit that (x1d - x2) and (y1d -
y2) are double values (not implicit promotion).
Cheers,
Laurent