-
Bug
-
Resolution: Unresolved
-
P4
-
8
It has become quite common to use the following code
.rows((int) INSTRUCTIONS.lines().count() + 1)
to set the number of rows for PassFailJFrame. Yet the `String.lines` method is not available in Java 8.
During backport process, this code was replaced with
INSTRUCTIONS.split("\n").length
which is correct.
Other tests use
INSTRUCTIONS.length()/45
which will produce the wrong number and the instruction text will not fit.
AfterJDK-8340308 is backported to Java 8, these usages can be removed completely, as the PassFailJFrame framework will provide the expected default. If required, the number of rows can be adjusted by using the `rowsAdd` method.
.rows((int) INSTRUCTIONS.lines().count() + 1)
to set the number of rows for PassFailJFrame. Yet the `String.lines` method is not available in Java 8.
During backport process, this code was replaced with
INSTRUCTIONS.split("\n").length
which is correct.
Other tests use
INSTRUCTIONS.length()/45
which will produce the wrong number and the instruction text will not fit.
After
- relates to
-
JDK-8340308 PassFailJFrame: Make rows default to number of lines in instructions
- Resolved