Skip to content

Commit 58ca7af

Browse files
Apply suggestions from code review
Co-authored-by: Alexey Ivanov <alexey.ivanov@oracle.com>
1 parent 1724e0a commit 58ca7af

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

test/jdk/java/awt/print/PrinterJob/PageRanges.java

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -42,16 +42,16 @@
4242

4343
public class PageRanges implements Printable {
4444
private static final String INSTRUCTIONS = """
45-
This test prints two jobs, and tests that the specified range.
46-
of pages is printed. You must have a printer installed for this test.
47-
In the first dialog, select a page range of 2 to 3, and press OK
45+
This test prints two jobs and tests that the specified range
46+
of pages is printed.
47+
In the first dialog, select a page range of 2 to 3, and press OK.
4848
In the second dialog, select ALL, to print all pages (in total 5 pages).
49-
Collect the two print outs and confirm the jobs printed correctly.
49+
Collect the two print outs and confirm the jobs are printed correctly.
5050
""";
5151

5252
public static void main(String args[]) throws Exception {
5353
PrinterJob job = PrinterJob.getPrinterJob();
54-
if(job.getPrintService() == null) {
54+
if (job.getPrintService() == null) {
5555
throw new SkippedException("Printer not configured or available.");
5656
}
5757

@@ -74,7 +74,6 @@ public static void main(String args[]) throws Exception {
7474

7575
public int print(Graphics g, PageFormat pf, int pi)
7676
throws PrinterException {
77-
7877
if (pi >= 5) {
7978
return NO_SUCH_PAGE;
8079
}

test/jdk/java/awt/print/PrinterJob/PolylinePrintingTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
public class PolylinePrintingTest implements Printable {
4545
private static final String INSTRUCTIONS = """
4646
You must have a printer available to perform this test.
47-
OK the print dialog, and collect the printed page.
47+
Click OK in the print dialog and collect the printed page.
4848
Passing test : Output should show two identical chevrons.
4949
Failing test : The line joins will appear different.
5050
""";

0 commit comments

Comments
 (0)