]> git.ipfire.org Git - thirdparty/cups.git/blob - test/ipp-1.1.test
Merge changes from CUPS 1.6svn-r10002
[thirdparty/cups.git] / test / ipp-1.1.test
1 #
2 # "$Id$"
3 #
4 # IPP/1.1 test suite.
5 #
6 # Copyright 2007-2011 by Apple Inc.
7 # Copyright 2001-2006 by Easy Software Products. All rights reserved.
8 #
9 # These coded instructions, statements, and computer programs are the
10 # property of Apple Inc. and are protected by Federal copyright
11 # law. Distribution and use rights are outlined in the file "LICENSE.txt"
12 # which should have been included with this file. If this file is
13 # file is missing or damaged, see the license at "http://www.cups.org/".
14 #
15 # Usage:
16 #
17 # ./ipptool -f filename [-d document-uri=SOMEURI] -t printer-uri ipp-1.1.test
18 #
19
20 # Regular expressions for URI schemes:
21 #
22 # HTTP_URI_SCHEME - Matches strings beginning with http:// or https://
23 # IPP_URI_SCHEME - Matches strings beginning with ipp:// or ipps://
24
25 DEFINE HTTP_URI_SCHEME "/^https?://.+$$/"
26 DEFINE IPP_URI_SCHEME "/^ipps?://.+$$/"
27
28 # Test that a request-id value of 0 is not accepted.
29 #
30 # Required by: RFC 2911 section 3.1.1
31 {
32 NAME "RFC 2911 section 3.1.1: Bad request-id value 0"
33 REQUEST-ID 0
34 OPERATION Get-Printer-Attributes
35 GROUP operation-attributes-tag
36 ATTR charset attributes-charset utf-8
37 ATTR naturalLanguage attributes-natural-language en
38 ATTR uri printer-uri $uri
39
40 STATUS client-error-bad-request
41 EXPECT !printer-uri-supported
42 }
43
44
45 # Test that the first two attributes must be attributes-charset and
46 # attributes-natural-language.
47 #
48 # Required by: RFC 2911 section 3.1.4
49 {
50 NAME "RFC 2911 section 3.1.4: No Operation Attributes"
51 REQUEST-ID random
52 OPERATION Get-Printer-Attributes
53 GROUP operation-attributes-tag
54
55 STATUS client-error-bad-request
56 EXPECT !printer-uri-supported
57 }
58 {
59 NAME "RFC 2911 section 3.1.4: attributes-charset"
60 OPERATION Get-Printer-Attributes
61 GROUP operation-attributes-tag
62 ATTR charset attributes-charset utf-8
63 ATTR uri printer-uri $uri
64
65 STATUS client-error-bad-request
66 EXPECT !printer-uri-supported
67 }
68 {
69 NAME "RFC 2911 section 3.1.4: attributes-natural-language"
70 OPERATION Get-Printer-Attributes
71 GROUP operation-attributes-tag
72 ATTR naturalLanguage attributes-natural-language en
73 ATTR uri printer-uri $uri
74
75 STATUS client-error-bad-request
76 EXPECT !printer-uri-supported
77 }
78 {
79 NAME "RFC 2911 section 3.1.4: attributes-natural-language + attributes-charset"
80 OPERATION Get-Printer-Attributes
81 GROUP operation-attributes-tag
82 ATTR naturalLanguage attributes-natural-language en
83 ATTR charset attributes-charset utf-8
84 ATTR uri printer-uri $uri
85
86 STATUS client-error-bad-request
87 EXPECT !printer-uri-supported
88 }
89 {
90 NAME "RFC 2911 section 3.1.4: attributes-charset + attributes-natural-language"
91 OPERATION Get-Printer-Attributes
92 GROUP operation-attributes-tag
93 ATTR charset attributes-charset utf-8
94 ATTR naturalLanguage attributes-natural-language en
95 ATTR uri printer-uri $uri
96
97 STATUS successful-ok
98 EXPECT printer-uri-supported OF-TYPE uri WITH-VALUE "$IPP_URI_SCHEME"
99 }
100
101
102 # Test that bad IPP versions are not supported.
103 #
104 # Required by: RFC 2911 section 3.1.8
105 {
106 # The name of the test...
107 NAME "RFC 2911 section 3.1.8: Unsupported IPP version 0.0"
108 VERSION 0.0
109 OPERATION Get-Printer-Attributes
110 GROUP operation-attributes-tag
111 ATTR charset attributes-charset utf-8
112 ATTR naturalLanguage attributes-natural-language en
113 ATTR uri printer-uri $uri
114
115 STATUS server-error-version-not-supported
116 EXPECT !printer-uri-supported
117 }
118
119
120 # Test that printer operations require the printer-uri operation attribute.
121 #
122 # Required by: RFC 2911 section 3.2
123 {
124 NAME "RFC 2911 section 3.2: No printer-uri operation attribute"
125 OPERATION Get-Printer-Attributes
126 GROUP operation-attributes-tag
127 ATTR charset attributes-charset utf-8
128 ATTR naturalLanguage attributes-natural-language en
129
130 STATUS client-error-bad-request
131 EXPECT !printer-uri-supported
132 }
133
134
135 # Test Print-Job operation
136 #
137 # Required by: RFC 2911 section 3.2.1
138 {
139 NAME "RFC 2911 section 3.2.1: Print-Job Operation"
140 OPERATION Print-Job
141 GROUP operation-attributes-tag
142 ATTR charset attributes-charset utf-8
143 ATTR naturalLanguage attributes-natural-language en
144 ATTR uri printer-uri $uri
145 ATTR name requesting-user-name $user
146 ATTR name job-name $filename
147 ATTR boolean ipp-attribute-fidelity false
148 ATTR name document-name $filename
149 ATTR keyword compression none
150 ATTR mimeMediaType document-format $filetype
151 FILE $filename
152
153 STATUS successful-ok
154 STATUS client-error-document-format-not-supported
155 STATUS server-error-job-canceled
156 STATUS server-error-busy REPEAT-MATCH
157
158 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
159 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
160 WITH-VALUE >0
161 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
162 WITH-VALUE 3,4,5,6,7,8,9
163 EXPECT job-state WITH-VALUE 7,8,9 DEFINE-MATCH PRINT_JOB_COMPLETED
164 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
165 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
166 EXPECT ?number-of-intervening-jobs OF-TYPE integer
167 IN-GROUP job-attributes-tag WITH-VALUE >-1
168 }
169
170 # Test Validate-Job operation
171 #
172 # Required by: RFC 2911 section 3.2.3
173 {
174 NAME "RFC 2911 section 3.2.3: Validate-Job Operation"
175 OPERATION Validate-Job
176 GROUP operation-attributes-tag
177 ATTR charset attributes-charset utf-8
178 ATTR naturalLanguage attributes-natural-language en
179 ATTR uri printer-uri $uri
180 ATTR name requesting-user-name $user
181 ATTR name job-name $filename
182 ATTR boolean ipp-attribute-fidelity false
183 ATTR name document-name $filename
184 ATTR keyword compression none
185 ATTR mimeMediaType document-format $filetype
186
187 STATUS successful-ok
188 }
189
190
191 # Test Get-Printer-Attributes operation
192 #
193 # Required by: RFC 2911 section 3.2.5
194 {
195 NAME "RFC 2911 section 3.2.5: Get-Printer-Attributes Operation (default)"
196 OPERATION Get-Printer-Attributes
197 GROUP operation-attributes-tag
198 ATTR charset attributes-charset utf-8
199 ATTR naturalLanguage attributes-natural-language en
200 ATTR uri printer-uri $uri
201 ATTR name requesting-user-name $user
202 ATTR mimeMediaType document-format $filetype
203
204 STATUS successful-ok
205
206 # Job template attributes
207 EXPECT ?copies-default OF-TYPE integer IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE >0
208 EXPECT ?copies-supported OF-TYPE rangeOfInteger IN-GROUP printer-attributes-tag
209 EXPECT ?finishings-default OF-TYPE enum IN-GROUP printer-attributes-tag
210 EXPECT ?finishings-supported OF-TYPE enum IN-GROUP printer-attributes-tag WITH-VALUE 3
211 EXPECT ?job-hold-until-default OF-TYPE keyword|name IN-GROUP printer-attributes-tag COUNT 1
212 EXPECT ?job-hold-until-supported OF-TYPE keyword|name IN-GROUP printer-attributes-tag WITH-VALUE no-hold
213 EXPECT ?job-priority-default OF-TYPE integer IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE >0,<101
214 EXPECT ?job-priority-supported OF-TYPE integer IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE >0,<101
215 EXPECT ?job-sheets-default OF-TYPE keyword|name IN-GROUP printer-attributes-tag
216 EXPECT ?job-sheets-supported OF-TYPE keyword|name IN-GROUP printer-attributes-tag WITH-VALUE none
217 EXPECT ?media-default OF-TYPE keyword|name IN-GROUP printer-attributes-tag COUNT 1
218 EXPECT ?media-ready OF-TYPE keyword|name IN-GROUP printer-attributes-tag
219 EXPECT ?media-supported OF-TYPE keyword|name IN-GROUP printer-attributes-tag
220 EXPECT ?multiple-document-handling-default OF-TYPE keyword IN-GROUP printer-attributes-tag WITH-VALUE "/^(single-document|separate-documents-uncollated-copies|separate-documents-collated-copies|single-document-new-sheet)$$/"
221 EXPECT ?multiple-document-handling-supported OF-TYPE keyword IN-GROUP printer-attributes-tag WITH-VALUE "/^(single-document|separate-documents-uncollated-copies|separate-documents-collated-copies|single-document-new-sheet)$$/"
222 EXPECT ?number-up-default OF-TYPE integer IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE >0
223 EXPECT ?number-up-supported OF-TYPE integer|rangeOfInteger IN-GROUP printer-attributes-tag WITH-VALUE >0
224 EXPECT ?number-up-supported WITH-VALUE 1
225 EXPECT ?orientation-requested-default OF-TYPE enum,no-value IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE no-value,3,4,5,6
226 EXPECT ?orientation-requested-supported OF-TYPE enum IN-GROUP printer-attributes-tag WITH-VALUE 3,4,5,6
227 EXPECT ?pages-ranges-supported OF-TYPE boolean IN-GROUP printer-attributes-tag
228 EXPECT ?print-quality-default OF-TYPE enum IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE 3,4,5
229 EXPECT ?print-quality-supported OF-TYPE enum IN-GROUP printer-attributes-tag WITH-VALUE 3,4,5
230 EXPECT ?printer-resolution-default OF-TYPE resolution IN-GROUP printer-attributes-tag COUNT 1
231 EXPECT ?printer-resolution-supported OF-TYPE resolution IN-GROUP printer-attributes-tag
232 EXPECT ?sides-default OF-TYPE keyword IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE "/^(one-sided|two-sided-long-edge|two-sided-short-edge)$$/"
233 EXPECT ?sides-supported OF-TYPE keyword IN-GROUP printer-attributes-tag WITH-VALUE "/^(one-sided|two-sided-long-edge|two-sided-short-edge)$$/"
234
235 # Job template attributes for specific tests...
236 EXPECT copies-supported WITH-VALUE >1 DEFINE-MATCH OPTIONAL_COPIES
237 EXPECT document-format-supported WITH-VALUE "application/pdf" DEFINE-MATCH OPTIONAL_PDF
238 EXPECT document-format-supported WITH-VALUE "application/postscript" DEFINE-MATCH OPTIONAL_POSTSCRIPT
239 EXPECT document-format-supported WITH-VALUE "image/jpeg" DEFINE-MATCH OPTIONAL_JPEG
240 EXPECT job-sheets-supported WITH-VALUE "standard" DEFINE-MATCH OPTIONAL_STANDARD_SHEET
241 EXPECT media-supported WITH-VALUE "iso_a4_210x297mm" DEFINE-MATCH OPTIONAL_A4_MEDIA
242 EXPECT media-supported WITH-VALUE "na_letter_8.5x11in" DEFINE-MATCH OPTIONAL_LETTER_MEDIA
243 EXPECT media-supported WITH-VALUE "na_index-4x6_4x6in" DEFINE-MATCH OPTIONAL_4X6_MEDIA
244 EXPECT number-up-supported WITH-VALUE 2 DEFINE-MATCH OPTIONAL_2UP
245 EXPECT print-quality WITH-VALUE 3 DEFINE-MATCH OPTIONAL_DRAFT_QUALITY
246 EXPECT print-quality WITH-VALUE 4 DEFINE-MATCH OPTIONAL_NORMAL_QUALITY
247 EXPECT print-quality WITH-VALUE 5 DEFINE-MATCH OPTIONAL_BEST_QUALITY
248 EXPECT sides-supported WITH-VALUE "two-sided-long-edge" DEFINE-MATCH OPTIONAL_DUPLEX
249
250 # Printer description attributes
251 EXPECT ?color-supported OF-TYPE boolean IN-GROUP printer-attributes-tag COUNT 1
252 EXPECT ?job-impressions-supported OF-TYPE rangeOfInteger IN-GROUP printer-attributes-tag COUNT 1
253 EXPECT ?job-k-octets-supported OF-TYPE rangeOfInteger IN-GROUP printer-attributes-tag COUNT 1
254 EXPECT ?job-media-sheets-supported OF-TYPE rangeOfInteger IN-GROUP printer-attributes-tag COUNT 1
255 EXPECT ?multiple-document-jobs-supported OF-TYPE boolean IN-GROUP printer-attributes-tag COUNT 1
256 EXPECT ?multiple-operation-time-out OF-TYPE integer IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE >0
257 EXPECT ?pages-per-minute OF-TYPE integer IN-GROUP printer-attributes-tag COUNT 1
258 EXPECT ?pages-per-minute-color OF-TYPE integer IN-GROUP printer-attributes-tag COUNT 1
259 EXPECT ?printer-driver-installer OF-TYPE uri IN-GROUP printer-attributes-tag COUNT 1
260 EXPECT ?printer-info OF-TYPE text IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE "/^.{0,127}$$/"
261 EXPECT ?printer-location OF-TYPE text IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE "/^.{0,127}$$/"
262 EXPECT ?printer-make-and-model OF-TYPE text IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE "/^.{0,127}$$/"
263 EXPECT ?printer-message-from-operator OF-TYPE text IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE "/^.{0,127}$$/"
264 EXPECT ?printer-more-info OF-TYPE uri IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE "$HTTP_URI_SCHEME"
265 EXPECT ?printer-more-info-manufacturer OF-TYPE uri IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE "$HTTP_URI_SCHEME"
266 EXPECT ?printer-state-message OF-TYPE text IN-GROUP printer-attributes-tag
267 EXPECT ?reference-uri-schemes-supported OF-TYPE uriScheme IN-GROUP printer-attributes-tag
268 EXPECT charset-configured OF-TYPE charset IN-GROUP printer-attributes-tag COUNT 1
269 EXPECT charset-supported OF-TYPE charset IN-GROUP printer-attributes-tag WITH-VALUE utf-8
270 EXPECT compression-supported OF-TYPE keyword IN-GROUP printer-attributes-tag WITH-VALUE none
271 EXPECT document-format-default OF-TYPE mimeMediaType IN-GROUP printer-attributes-tag COUNT 1
272 EXPECT document-format-supported OF-TYPE mimeMediaType IN-GROUP printer-attributes-tag
273 EXPECT generated-natural-language-supported OF-TYPE naturalLanguage IN-GROUP printer-attributes-tag
274 EXPECT ipp-versions-supported OF-TYPE keyword IN-GROUP printer-attributes-tag WITH-VALUE 1.1
275 EXPECT natural-language-configured OF-TYPE naturalLanguage IN-GROUP printer-attributes-tag COUNT 1
276 EXPECT pdl-override-supported OF-TYPE keyword IN-GROUP printer-attributes-tag COUNT 1
277 EXPECT printer-is-accepting-jobs OF-TYPE boolean IN-GROUP printer-attributes-tag COUNT 1
278 EXPECT printer-name OF-TYPE name IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE "/^.{1,127}$$/"
279 EXPECT printer-state OF-TYPE enum IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE 3,4,5
280 EXPECT printer-state-reasons OF-TYPE keyword IN-GROUP printer-attributes-tag
281 EXPECT printer-up-time OF-TYPE integer IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE >0
282 EXPECT printer-uri-supported OF-TYPE uri IN-GROUP printer-attributes-tag SAME-COUNT-AS uri-security-supported WITH-VALUE "$IPP_URI_SCHEME"
283 EXPECT queued-job-count OF-TYPE integer IN-GROUP printer-attributes-tag COUNT 1
284 EXPECT uri-authentication-supported OF-TYPE keyword IN-GROUP printer-attributes-tag
285 EXPECT uri-security-supported OF-TYPE keyword IN-GROUP printer-attributes-tag SAME-COUNT-AS uri-authentication-supported
286
287 # Operations
288 EXPECT operations-supported OF-TYPE enum IN-GROUP printer-attributes-tag WITH-VALUE 0x0002 # Print-Job
289 EXPECT operations-supported WITH-VALUE 0x0003 DEFINE-MATCH OPTIONAL_PRINT_URI # Print-URI
290 EXPECT operations-supported WITH-VALUE 0x0004 # Validate-Job
291 EXPECT operations-supported WITH-VALUE 0x0005 DEFINE-MATCH OPTIONAL_CREATE_JOB # Create-Job
292 EXPECT operations-supported WITH-VALUE 0x0006 DEFINE-MATCH OPTIONAL_SEND_DOCUMENT # Send-Document
293 EXPECT operations-supported WITH-VALUE 0x0007 DEFINE-MATCH OPTIONAL_SEND_URI # Send-URI
294 EXPECT operations-supported WITH-VALUE 0x0008 # Cancel-Job
295 EXPECT operations-supported WITH-VALUE 0x0009 # Get-Job-Attributes
296 EXPECT operations-supported WITH-VALUE 0x000a # Get-Jobs
297 EXPECT operations-supported WITH-VALUE 0x000b # Get-Printer-Attributes
298 EXPECT operations-supported WITH-VALUE 0x000c DEFINE-MATCH OPTIONAL_HOLD_JOB # Hold-Job
299 EXPECT operations-supported WITH-VALUE 0x000d DEFINE-MATCH OPTIONAL_RELEASE_JOB # Release-Job
300 EXPECT operations-supported WITH-VALUE 0x000e DEFINE-MATCH OPTIONAL_RESTART_JOB # Restart-Job
301 EXPECT operations-supported WITH-VALUE 0x0010 DEFINE-MATCH OPTIONAL_PAUSE_PRINTER # Pause-Printer
302 EXPECT operations-supported WITH-VALUE 0x0011 DEFINE-MATCH OPTIONAL_RESUME_PRINTER # Resume-Printer
303 EXPECT operations-supported WITH-VALUE 0x0012 DEFINE-MATCH OPTIONAL_PURGE_JOBS # Purge-Jobs
304 }
305
306
307 # Test Get-Printer-Attributes operation with requested-attributes
308 #
309 # Required by: RFC 2911 section 3.2.5
310 {
311 NAME "RFC 2911 section 3.2.5: Get-Printer-Attributes Operation (requested-attributes)"
312 OPERATION Get-Printer-Attributes
313 GROUP operation-attributes-tag
314 ATTR charset attributes-charset utf-8
315 ATTR naturalLanguage attributes-natural-language en
316 ATTR uri printer-uri $uri
317 ATTR name requesting-user-name $user
318 ATTR mimeMediaType document-format $filetype
319 ATTR keyword requested-attributes printer-uri-supported
320
321 STATUS successful-ok
322
323 EXPECT printer-uri-supported OF-TYPE uri IN-GROUP printer-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
324 EXPECT !printer-name
325 }
326
327
328 # Test Get-Jobs operation
329 #
330 # Required by: RFC 2911 section 3.2.6
331 {
332 NAME "RFC 2911 section 3.2.6: Get-Jobs Operation (default)"
333 OPERATION Get-Jobs
334 GROUP operation-attributes-tag
335 ATTR charset attributes-charset utf-8
336 ATTR naturalLanguage attributes-natural-language en
337 ATTR uri printer-uri $uri
338 ATTR name requesting-user-name $user
339
340 STATUS successful-ok
341 EXPECT ?job-id OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >0
342 EXPECT ?job-uri OF-TYPE uri IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE "$IPP_URI_SCHEME"
343 EXPECT !job-printer-uri
344 EXPECT !job-more-info
345 EXPECT !job-name
346 EXPECT !job-originating-user-name
347 EXPECT !job-state
348 EXPECT !job-state-reasons
349 EXPECT !job-state-message
350 EXPECT !job-detailed-status-messages
351 EXPECT !number-of-documents
352 EXPECT !output-device-assigned
353 EXPECT !time-at-creation
354 EXPECT !time-at-processing
355 EXPECT !time-at-completed
356 EXPECT !job-printer-up-time
357 EXPECT !date-time-at-creation
358 EXPECT !date-time-at-processing
359 EXPECT !date-time-at-completed
360 EXPECT !number-of-intervening-jobs
361 EXPECT !job-message-from-operator
362 EXPECT !job-k-octets
363 EXPECT !job-impressions
364 EXPECT !job-media-sheets
365 EXPECT !job-k-octets-processed
366 EXPECT !job-impressions-completed
367 EXPECT !job-media-sheets-completed
368
369 EXPECT !copies
370 EXPECT !finishings
371 EXPECT !job-hold-until
372 EXPECT !job-priority
373 EXPECT !job-sheets
374 EXPECT !media
375 EXPECT !multiple-document-handling
376 EXPECT !number-up
377 EXPECT !orientation-requested
378 EXPECT !pages-ranges
379 EXPECT !print-quality
380 EXPECT !printer-resolution
381 EXPECT !sides
382 }
383
384
385 # Test Get-Jobs operation
386 #
387 # Required by: RFC 2911 section 3.2.6
388 {
389 SKIP-IF-DEFINED PRINT_JOB_COMPLETED
390
391 NAME "RFC 2911 section 3.2.6: Get-Jobs Operation (requested-attributes)"
392 OPERATION Get-Jobs
393 GROUP operation-attributes-tag
394 ATTR charset attributes-charset utf-8
395 ATTR naturalLanguage attributes-natural-language en
396 ATTR uri printer-uri $uri
397 ATTR name requesting-user-name $user
398 ATTR keyword requested-attributes all
399
400 STATUS successful-ok
401 EXPECT job-id OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >0
402 EXPECT job-uri OF-TYPE uri IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE "$IPP_URI_SCHEME"
403 EXPECT job-printer-uri OF-TYPE uri IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE "$IPP_URI_SCHEME"
404 EXPECT ?job-more-info OF-TYPE uri IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE "$HTTP_URI_SCHEME"
405 EXPECT job-name OF-TYPE name IN-GROUP job-attributes-tag COUNT 1
406 EXPECT job-originating-user-name OF-TYPE name IN-GROUP job-attributes-tag COUNT 1
407 EXPECT job-state OF-TYPE enum IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >2,<10
408 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
409 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag COUNT 1
410 EXPECT ?job-detailed-status-messages OF-TYPE text IN-GROUP job-attributes-tag
411 EXPECT ?number-of-documents OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
412 EXPECT ?output-device-assigned OF-TYPE name IN-GROUP job-attributes-tag COUNT 1
413 EXPECT time-at-creation OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE no-value,>-1
414 EXPECT time-at-processing OF-TYPE no-value,integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE no-value,>-1
415 EXPECT time-at-completed OF-TYPE no-value,integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE no-value,>-1
416 EXPECT job-printer-up-time OF-TYPE no-value,integer IN-GROUP job-attributes-tag COUNT 1
417 EXPECT ?date-time-at-creation OF-TYPE no-value,dateTime IN-GROUP job-attributes-tag COUNT 1
418 EXPECT ?date-time-at-processing OF-TYPE no-value,dateTime IN-GROUP job-attributes-tag COUNT 1
419 EXPECT ?date-time-at-completed OF-TYPE no-value,dateTime IN-GROUP job-attributes-tag COUNT 1
420 EXPECT ?number-of-intervening-jobs OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
421 EXPECT ?job-message-from-operator OF-TYPE text IN-GROUP job-attributes-tag COUNT 1
422 EXPECT ?job-k-octets OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
423 EXPECT ?job-impressions OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
424 EXPECT ?job-media-sheets OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
425 EXPECT ?job-k-octets-processed OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
426 EXPECT ?job-impressions-completed OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
427 EXPECT ?job-media-sheets-completed OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
428
429 EXPECT ?copies OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >0
430 EXPECT ?finishings OF-TYPE enum IN-GROUP job-attributes-tag
431 EXPECT ?job-hold-until OF-TYPE keyword|name IN-GROUP job-attributes-tag COUNT 1
432 EXPECT ?job-priority OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >0,<101
433 EXPECT ?job-sheets OF-TYPE keyword|name IN-GROUP job-attributes-tag
434 EXPECT ?media OF-TYPE keyword|name IN-GROUP job-attributes-tag COUNT 1
435 EXPECT ?multiple-document-handling OF-TYPE keyword IN-GROUP job-attributes-tag WITH-VALUE "/^(single-document|separate-documents-uncollated-copies|separate-documents-collated-copies|single-document-new-sheet)$$/"
436 EXPECT ?number-up OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >0
437 EXPECT ?orientation-requested OF-TYPE enum IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE 3,4,5,6
438 EXPECT ?pages-ranges OF-TYPE rangeOfInteger IN-GROUP job-attributes-tag
439 EXPECT ?print-quality OF-TYPE enum IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE 3,4,5
440 EXPECT ?printer-resolution OF-TYPE resolution IN-GROUP job-attributes-tag COUNT 1
441 EXPECT ?sides OF-TYPE keyword IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE "/^(one-sided|two-sided-long-edge|two-sided-short-edge)$$/"
442 }
443
444
445 # Test Get-Jobs operation
446 #
447 # Required by: RFC 2911 section 3.2.6
448 {
449 SKIP-IF-DEFINED PRINT_JOB_COMPLETED
450
451 NAME "RFC 2911 section 3.2.6: Get-Jobs Operation (my-jobs)"
452 OPERATION Get-Jobs
453 GROUP operation-attributes-tag
454 ATTR charset attributes-charset utf-8
455 ATTR naturalLanguage attributes-natural-language en
456 ATTR uri printer-uri $uri
457 ATTR name requesting-user-name $user
458 ATTR boolean my-jobs true
459
460 STATUS successful-ok
461 EXPECT job-id OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >0
462 EXPECT job-uri OF-TYPE uri IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE "$IPP_URI_SCHEME"
463 EXPECT !job-printer-uri
464 EXPECT !job-more-info
465 EXPECT !job-name
466 EXPECT !job-originating-user-name
467 EXPECT !job-state
468 EXPECT !job-state-reasons
469 EXPECT !job-state-message
470 EXPECT !job-detailed-status-messages
471 EXPECT !number-of-documents
472 EXPECT !output-device-assigned
473 EXPECT !time-at-creation
474 EXPECT !time-at-processing
475 EXPECT !time-at-completed
476 EXPECT !job-printer-up-time
477 EXPECT !date-time-at-creation
478 EXPECT !date-time-at-processing
479 EXPECT !date-time-at-completed
480 EXPECT !number-of-intervening-jobs
481 EXPECT !job-message-from-operator
482 EXPECT !job-k-octets
483 EXPECT !job-impressions
484 EXPECT !job-media-sheets
485 EXPECT !job-k-octets-processed
486 EXPECT !job-impressions-completed
487 EXPECT !job-media-sheets-completed
488
489 EXPECT !copies
490 EXPECT !finishings
491 EXPECT !job-hold-until
492 EXPECT !job-priority
493 EXPECT !job-sheets
494 EXPECT !media
495 EXPECT !multiple-document-handling
496 EXPECT !number-up
497 EXPECT !orientation-requested
498 EXPECT !pages-ranges
499 EXPECT !print-quality
500 EXPECT !printer-resolution
501 EXPECT !sides
502 }
503
504
505 # Test Get-Jobs operation
506 #
507 # Required by: RFC 2911 section 3.2.6
508 {
509 SKIP-IF-DEFINED PRINT_JOB_COMPLETED
510
511 # Skip this test when doing authenticated printing since we'll always
512 # use the authenticated username over the requesting-user-name value.
513 SKIP-IF-DEFINED uriuser
514
515 NAME "RFC 2911 section 3.2.6: Get-Jobs Operation (my-jobs different user)"
516 OPERATION Get-Jobs
517 GROUP operation-attributes-tag
518 ATTR charset attributes-charset utf-8
519 ATTR naturalLanguage attributes-natural-language en
520 ATTR uri printer-uri $uri
521 ATTR name requesting-user-name not-$user
522 ATTR boolean my-jobs true
523
524 STATUS successful-ok
525 EXPECT !job-id
526 EXPECT !job-uri
527 EXPECT !job-printer-uri
528 EXPECT !job-more-info
529 EXPECT !job-name
530 EXPECT !job-originating-user-name
531 EXPECT !job-state
532 EXPECT !job-state-reasons
533 EXPECT !job-state-message
534 EXPECT !job-detailed-status-messages
535 EXPECT !number-of-documents
536 EXPECT !output-device-assigned
537 EXPECT !time-at-creation
538 EXPECT !time-at-processing
539 EXPECT !time-at-completed
540 EXPECT !job-printer-up-time
541 EXPECT !date-time-at-creation
542 EXPECT !date-time-at-processing
543 EXPECT !date-time-at-completed
544 EXPECT !number-of-intervening-jobs
545 EXPECT !job-message-from-operator
546 EXPECT !job-k-octets
547 EXPECT !job-impressions
548 EXPECT !job-media-sheets
549 EXPECT !job-k-octets-processed
550 EXPECT !job-impressions-completed
551 EXPECT !job-media-sheets-completed
552
553 EXPECT !copies
554 EXPECT !finishings
555 EXPECT !job-hold-until
556 EXPECT !job-priority
557 EXPECT !job-sheets
558 EXPECT !media
559 EXPECT !multiple-document-handling
560 EXPECT !number-up
561 EXPECT !orientation-requested
562 EXPECT !pages-ranges
563 EXPECT !print-quality
564 EXPECT !printer-resolution
565 EXPECT !sides
566 }
567
568
569 # Test Get-Jobs operation
570 #
571 # Required by: RFC 2911 section 3.2.6
572 {
573 SKIP-IF-DEFINED PRINT_JOB_COMPLETED
574
575 NAME "RFC 2911 section 3.2.6: Get-Jobs Operation (which-jobs=not-completed)"
576 OPERATION Get-Jobs
577 GROUP operation-attributes-tag
578 ATTR charset attributes-charset utf-8
579 ATTR naturalLanguage attributes-natural-language en
580 ATTR uri printer-uri $uri
581 ATTR name requesting-user-name $user
582 ATTR keyword which-jobs not-completed
583
584 STATUS successful-ok
585 EXPECT job-id OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >0
586 EXPECT job-uri OF-TYPE uri IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE "$IPP_URI_SCHEME"
587 EXPECT !job-printer-uri
588 EXPECT !job-more-info
589 EXPECT !job-name
590 EXPECT !job-originating-user-name
591 EXPECT !job-state
592 EXPECT !job-state-reasons
593 EXPECT !job-state-message
594 EXPECT !job-detailed-status-messages
595 EXPECT !number-of-documents
596 EXPECT !output-device-assigned
597 EXPECT !time-at-creation
598 EXPECT !time-at-processing
599 EXPECT !time-at-completed
600 EXPECT !job-printer-up-time
601 EXPECT !date-time-at-creation
602 EXPECT !date-time-at-processing
603 EXPECT !date-time-at-completed
604 EXPECT !number-of-intervening-jobs
605 EXPECT !job-message-from-operator
606 EXPECT !job-k-octets
607 EXPECT !job-impressions
608 EXPECT !job-media-sheets
609 EXPECT !job-k-octets-processed
610 EXPECT !job-impressions-completed
611 EXPECT !job-media-sheets-completed
612
613 EXPECT !copies
614 EXPECT !finishings
615 EXPECT !job-hold-until
616 EXPECT !job-priority
617 EXPECT !job-sheets
618 EXPECT !media
619 EXPECT !multiple-document-handling
620 EXPECT !number-up
621 EXPECT !orientation-requested
622 EXPECT !pages-ranges
623 EXPECT !print-quality
624 EXPECT !printer-resolution
625 EXPECT !sides
626 }
627
628
629 # Test Get-Jobs operation
630 #
631 # Required by: RFC 2911 section 3.2.6
632 {
633 NAME "RFC 2911 section 3.2.6: Get-Jobs Operation (which-jobs=completed)"
634 OPERATION Get-Jobs
635 GROUP operation-attributes-tag
636 ATTR charset attributes-charset utf-8
637 ATTR naturalLanguage attributes-natural-language en
638 ATTR uri printer-uri $uri
639 ATTR name requesting-user-name $user
640 ATTR keyword which-jobs completed
641 DELAY 20
642
643 STATUS successful-ok
644 EXPECT job-id OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >0
645 EXPECT job-uri OF-TYPE uri IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE "$IPP_URI_SCHEME"
646 EXPECT !job-printer-uri
647 EXPECT !job-more-info
648 EXPECT !job-name
649 EXPECT !job-originating-user-name
650 EXPECT !job-state
651 EXPECT !job-state-reasons
652 EXPECT !job-state-message
653 EXPECT !job-detailed-status-messages
654 EXPECT !number-of-documents
655 EXPECT !output-device-assigned
656 EXPECT !time-at-creation
657 EXPECT !time-at-processing
658 EXPECT !time-at-completed
659 EXPECT !job-printer-up-time
660 EXPECT !date-time-at-creation
661 EXPECT !date-time-at-processing
662 EXPECT !date-time-at-completed
663 EXPECT !number-of-intervening-jobs
664 EXPECT !job-message-from-operator
665 EXPECT !job-k-octets
666 EXPECT !job-impressions
667 EXPECT !job-media-sheets
668 EXPECT !job-k-octets-processed
669 EXPECT !job-impressions-completed
670 EXPECT !job-media-sheets-completed
671
672 EXPECT !copies
673 EXPECT !finishings
674 EXPECT !job-hold-until
675 EXPECT !job-priority
676 EXPECT !job-sheets
677 EXPECT !media
678 EXPECT !multiple-document-handling
679 EXPECT !number-up
680 EXPECT !orientation-requested
681 EXPECT !pages-ranges
682 EXPECT !print-quality
683 EXPECT !printer-resolution
684 EXPECT !sides
685 }
686
687
688 # Test Get-Jobs operation
689 #
690 # Required by: RFC 2911 section 3.2.6
691 {
692 SKIP-IF-DEFINED PRINT_JOB_COMPLETED
693
694 NAME "RFC 2911 section 3.2.6: Get-Jobs Operation (which-jobs, requested-attributes)"
695 OPERATION Get-Jobs
696 GROUP operation-attributes-tag
697 ATTR charset attributes-charset utf-8
698 ATTR naturalLanguage attributes-natural-language en
699 ATTR uri printer-uri $uri
700 ATTR name requesting-user-name $user
701 ATTR keyword requested-attributes all
702 ATTR keyword which-jobs completed
703
704 STATUS successful-ok
705 EXPECT job-id OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >0
706 EXPECT job-uri OF-TYPE uri IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE "$IPP_URI_SCHEME"
707 EXPECT job-printer-uri OF-TYPE uri IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE "$IPP_URI_SCHEME"
708 EXPECT ?job-more-info OF-TYPE uri IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE "$HTTP_URI_SCHEME"
709 EXPECT job-name OF-TYPE name IN-GROUP job-attributes-tag COUNT 1
710 EXPECT job-originating-user-name OF-TYPE name IN-GROUP job-attributes-tag COUNT 1
711 EXPECT job-state OF-TYPE enum IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >2,<10
712 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
713 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag COUNT 1
714 EXPECT ?job-detailed-status-messages OF-TYPE text IN-GROUP job-attributes-tag
715 EXPECT ?number-of-documents OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
716 EXPECT ?output-device-assigned OF-TYPE name IN-GROUP job-attributes-tag COUNT 1
717 EXPECT time-at-creation OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE no-value,>-1
718 EXPECT time-at-processing OF-TYPE no-value,integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE no-value,>-1
719 EXPECT time-at-completed OF-TYPE no-value,integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE no-value,>-1
720 EXPECT job-printer-up-time OF-TYPE no-value,integer IN-GROUP job-attributes-tag COUNT 1
721 EXPECT ?date-time-at-creation OF-TYPE no-value,dateTime IN-GROUP job-attributes-tag COUNT 1
722 EXPECT ?date-time-at-processing OF-TYPE no-value,dateTime IN-GROUP job-attributes-tag COUNT 1
723 EXPECT ?date-time-at-completed OF-TYPE no-value,dateTime IN-GROUP job-attributes-tag COUNT 1
724 EXPECT ?number-of-intervening-jobs OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
725 EXPECT ?job-message-from-operator OF-TYPE text IN-GROUP job-attributes-tag COUNT 1
726 EXPECT ?job-k-octets OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
727 EXPECT ?job-impressions OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
728 EXPECT ?job-media-sheets OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
729 EXPECT ?job-k-octets-processed OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
730 EXPECT ?job-impressions-completed OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
731 EXPECT ?job-media-sheets-completed OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
732
733 EXPECT ?copies OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >0
734 EXPECT ?finishings OF-TYPE enum IN-GROUP job-attributes-tag
735 EXPECT ?job-hold-until OF-TYPE keyword|name IN-GROUP job-attributes-tag COUNT 1
736 EXPECT ?job-priority OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >0,<101
737 EXPECT ?job-sheets OF-TYPE keyword|name IN-GROUP job-attributes-tag
738 EXPECT ?media OF-TYPE keyword|name IN-GROUP job-attributes-tag COUNT 1
739 EXPECT ?multiple-document-handling OF-TYPE keyword IN-GROUP job-attributes-tag WITH-VALUE "/^(single-document|separate-documents-uncollated-copies|separate-documents-collated-copies|single-document-new-sheet)$$/"
740 EXPECT ?number-up OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >0
741 EXPECT ?orientation-requested OF-TYPE enum IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE 3,4,5,6
742 EXPECT ?pages-ranges OF-TYPE rangeOfInteger IN-GROUP job-attributes-tag
743 EXPECT ?print-quality OF-TYPE enum IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE 3,4,5
744 EXPECT ?printer-resolution OF-TYPE resolution IN-GROUP job-attributes-tag COUNT 1
745 EXPECT ?sides OF-TYPE keyword IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE "/^(one-sided|two-sided-long-edge|two-sided-short-edge)$$/"
746 }
747
748
749 # Test Cancel-Job operation
750 #
751 # Required by: RFC 2911 section 3.3.3
752 {
753 NAME "RFC 2911 section 3.3.3: Cancel-Job Operation (completed job)"
754 OPERATION Cancel-Job
755 GROUP operation-attributes-tag
756 ATTR charset attributes-charset utf-8
757 ATTR naturalLanguage attributes-natural-language en
758 ATTR uri printer-uri $uri
759 ATTR integer job-id $job-id
760 ATTR name requesting-user-name $user
761
762 STATUS client-error-not-possible
763 }
764
765
766 # Test Print-Job operation
767 #
768 # Required by: RFC 2911 section 3.2.1
769 {
770 NAME "RFC 2911 section 3.2.1: Print-Job Operation"
771 OPERATION Print-Job
772 GROUP operation-attributes-tag
773 ATTR charset attributes-charset utf-8
774 ATTR naturalLanguage attributes-natural-language en
775 ATTR uri printer-uri $uri
776 ATTR name requesting-user-name $user
777 ATTR name job-name $filename
778 ATTR boolean ipp-attribute-fidelity false
779 ATTR name document-name $filename
780 ATTR keyword compression none
781 ATTR mimeMediaType document-format $filetype
782 FILE $filename
783
784 STATUS successful-ok
785 STATUS client-error-document-format-not-supported
786 STATUS server-error-job-canceled
787 STATUS server-error-busy REPEAT-MATCH
788
789 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
790 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
791 WITH-VALUE >0
792 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
793 WITH-VALUE 3,4,5,6,7,8,9
794 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
795 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
796 EXPECT ?number-of-intervening-jobs OF-TYPE integer
797 IN-GROUP job-attributes-tag WITH-VALUE >-1
798 }
799
800
801 # Test Cancel-Job operation
802 #
803 # Required by: RFC 2911 section 3.3.3
804 {
805 NAME "RFC 2911 section 3.3.3: Cancel-Job Operation (pending/processing job)"
806 OPERATION Cancel-Job
807 GROUP operation-attributes-tag
808 ATTR charset attributes-charset utf-8
809 ATTR naturalLanguage attributes-natural-language en
810 ATTR uri printer-uri $uri
811 ATTR integer job-id $job-id
812 ATTR name requesting-user-name $user
813
814 STATUS successful-ok
815 STATUS client-error-not-possible
816 }
817
818
819 # Test Get-Job-Attributes operation
820 #
821 # Required by: RFC 2911 section 3.3.4
822 {
823 NAME "RFC 2911 section 3.3.4: Get-Job-Attributes Operation"
824 OPERATION Get-Job-Attributes
825 GROUP operation-attributes-tag
826 ATTR charset attributes-charset utf-8
827 ATTR naturalLanguage attributes-natural-language en
828 ATTR uri printer-uri $uri
829 ATTR integer job-id $job-id
830 ATTR name requesting-user-name $user
831
832 STATUS successful-ok
833 EXPECT job-id OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >0
834 EXPECT job-uri OF-TYPE uri IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE "$IPP_URI_SCHEME"
835 EXPECT job-printer-uri OF-TYPE uri IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE "$IPP_URI_SCHEME"
836 EXPECT ?job-more-info OF-TYPE uri IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE "$HTTP_URI_SCHEME"
837 EXPECT job-name OF-TYPE name IN-GROUP job-attributes-tag COUNT 1
838 EXPECT job-originating-user-name OF-TYPE name IN-GROUP job-attributes-tag COUNT 1
839 EXPECT job-state OF-TYPE enum IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >2,<10
840 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
841 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag COUNT 1
842 EXPECT ?job-detailed-status-messages OF-TYPE text IN-GROUP job-attributes-tag
843 EXPECT ?number-of-documents OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
844 EXPECT ?output-device-assigned OF-TYPE name IN-GROUP job-attributes-tag COUNT 1
845 EXPECT time-at-creation OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE no-value,>-1
846 EXPECT time-at-processing OF-TYPE no-value,integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE no-value,>-1
847 EXPECT time-at-completed OF-TYPE no-value,integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE no-value,>-1
848 EXPECT job-printer-up-time OF-TYPE no-value,integer IN-GROUP job-attributes-tag COUNT 1
849 EXPECT ?date-time-at-creation OF-TYPE no-value,dateTime IN-GROUP job-attributes-tag COUNT 1
850 EXPECT ?date-time-at-processing OF-TYPE no-value,dateTime IN-GROUP job-attributes-tag COUNT 1
851 EXPECT ?date-time-at-completed OF-TYPE no-value,dateTime IN-GROUP job-attributes-tag COUNT 1
852 EXPECT ?number-of-intervening-jobs OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
853 EXPECT ?job-message-from-operator OF-TYPE text IN-GROUP job-attributes-tag COUNT 1
854 EXPECT ?job-k-octets OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
855 EXPECT ?job-impressions OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
856 EXPECT ?job-media-sheets OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
857 EXPECT ?job-k-octets-processed OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
858 EXPECT ?job-impressions-completed OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
859 EXPECT ?job-media-sheets-completed OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1
860
861 EXPECT ?copies OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >0
862 EXPECT ?finishings OF-TYPE enum IN-GROUP job-attributes-tag
863 EXPECT ?job-hold-until OF-TYPE keyword|name IN-GROUP job-attributes-tag COUNT 1
864 EXPECT ?job-priority OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >0,<101
865 EXPECT ?job-sheets OF-TYPE keyword|name IN-GROUP job-attributes-tag
866 EXPECT ?media OF-TYPE keyword|name IN-GROUP job-attributes-tag COUNT 1
867 EXPECT ?multiple-document-handling OF-TYPE keyword IN-GROUP job-attributes-tag WITH-VALUE "/^(single-document|separate-documents-uncollated-copies|separate-documents-collated-copies|single-document-new-sheet)$$/"
868 EXPECT ?number-up OF-TYPE integer IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE >0
869 EXPECT ?orientation-requested OF-TYPE enum IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE 3,4,5,6
870 EXPECT ?pages-ranges OF-TYPE rangeOfInteger IN-GROUP job-attributes-tag
871 EXPECT ?print-quality OF-TYPE enum IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE 3,4,5
872 EXPECT ?printer-resolution OF-TYPE resolution IN-GROUP job-attributes-tag COUNT 1
873 EXPECT ?sides OF-TYPE keyword IN-GROUP job-attributes-tag COUNT 1 WITH-VALUE "/^(one-sided|two-sided-long-edge|two-sided-short-edge)$$/"
874 }
875
876
877 # Test Print-URI operation
878 #
879 # Defined by: RFC 2911 section 3.2.2
880 {
881 SKIP-IF-NOT-DEFINED OPTIONAL_PRINT_URI
882 SKIP-IF-NOT-DEFINED document-uri
883
884 NAME "RFC 2911 section 3.2.2: Print-URI Operation"
885 OPERATION Print-URI
886 GROUP operation-attributes-tag
887 ATTR charset attributes-charset utf-8
888 ATTR naturalLanguage attributes-natural-language en
889 ATTR uri printer-uri $uri
890 ATTR name requesting-user-name $user
891 ATTR name job-name $filename
892 ATTR boolean ipp-attribute-fidelity false
893 ATTR name document-name $filename
894 ATTR keyword compression none
895 ATTR uri document-uri $document-uri
896
897 STATUS successful-ok
898 STATUS server-error-job-canceled
899 STATUS server-error-busy REPEAT-MATCH
900
901 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
902 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
903 WITH-VALUE >0
904 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
905 WITH-VALUE 3,4,5,6,7,8,9
906 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
907 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
908 EXPECT ?number-of-intervening-jobs OF-TYPE integer
909 IN-GROUP job-attributes-tag WITH-VALUE >-1
910 }
911
912
913 # Test Print-URI operation with bad document-uri
914 #
915 # Defined by: RFC 2911 section 3.2.2
916 {
917 SKIP-IF-NOT-DEFINED OPTIONAL_PRINT_URI
918
919 NAME "Print-URI with bad URI: Print-URI Operation"
920 OPERATION Print-URI
921 GROUP operation-attributes-tag
922 ATTR charset attributes-charset utf-8
923 ATTR naturalLanguage attributes-natural-language en
924 ATTR uri printer-uri $uri
925 ATTR name requesting-user-name $user
926 ATTR name job-name $filename
927 ATTR boolean ipp-attribute-fidelity false
928 ATTR name document-name $filename
929 ATTR keyword compression none
930 ATTR uri document-uri "bogus://bogus"
931
932 STATUS client-error-uri-scheme-not-supported
933
934 EXPECT !job-uri
935 EXPECT !job-id
936 EXPECT !job-state
937 EXPECT !job-state-reasons
938 EXPECT !job-state-message
939 }
940
941
942 # Test Create-Job and Send-Document operations
943 #
944 # Defined by: RFC 2911 section 3.2.4 and 3.3.1
945 {
946 SKIP-IF-NOT-DEFINED OPTIONAL_CREATE_JOB
947 SKIP-IF-NOT-DEFINED OPTIONAL_SEND_DOCUMENT
948
949 NAME "RFC 2911 section 3.2.4: Create-Job Operation"
950 OPERATION Create-Job
951 GROUP operation-attributes-tag
952 ATTR charset attributes-charset utf-8
953 ATTR naturalLanguage attributes-natural-language en
954 ATTR uri printer-uri $uri
955 ATTR name requesting-user-name $user
956 ATTR name job-name $filename
957 ATTR boolean ipp-attribute-fidelity false
958
959 STATUS successful-ok
960
961 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
962 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
963 WITH-VALUE >0
964 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
965 WITH-VALUE 3,4,5,6,7,8,9
966 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
967 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
968 EXPECT ?number-of-intervening-jobs OF-TYPE integer
969 IN-GROUP job-attributes-tag WITH-VALUE >-1
970 }
971
972 {
973 SKIP-IF-NOT-DEFINED OPTIONAL_CREATE_JOB
974 SKIP-IF-NOT-DEFINED OPTIONAL_SEND_DOCUMENT
975
976 NAME "RFC 2911 section 3.3.1: Send-Document Operation"
977 OPERATION Send-Document
978 GROUP operation-attributes-tag
979 ATTR charset attributes-charset utf-8
980 ATTR naturalLanguage attributes-natural-language en
981 ATTR uri printer-uri $uri
982 ATTR integer job-id $job-id
983 ATTR name requesting-user-name $user
984 ATTR boolean last-document true
985 ATTR name document-name $filename
986 ATTR keyword compression none
987 ATTR mimeMediaType document-format $filetype
988 FILE $filename
989
990 STATUS successful-ok
991 STATUS client-error-document-format-not-supported
992 STATUS server-error-job-canceled
993 }
994
995 # Test Create-Job and Send-Document operations (no last-document)
996 #
997 # Defined by: RFC 2911 section 3.2.4 and 3.3.1
998 {
999 SKIP-IF-NOT-DEFINED OPTIONAL_CREATE_JOB
1000 SKIP-IF-NOT-DEFINED OPTIONAL_SEND_DOCUMENT
1001
1002 NAME "Send-Document missing last-document: Create-Job Operation"
1003 OPERATION Create-Job
1004 GROUP operation-attributes-tag
1005 ATTR charset attributes-charset utf-8
1006 ATTR naturalLanguage attributes-natural-language en
1007 ATTR uri printer-uri $uri
1008 ATTR name requesting-user-name $user
1009 ATTR name job-name $filename
1010 ATTR boolean ipp-attribute-fidelity false
1011
1012 STATUS successful-ok
1013
1014 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1015 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1016 WITH-VALUE >0
1017 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1018 WITH-VALUE 3,4,5,6,7,8,9
1019 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1020 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1021 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1022 IN-GROUP job-attributes-tag WITH-VALUE >-1
1023 }
1024
1025 {
1026 SKIP-IF-NOT-DEFINED OPTIONAL_CREATE_JOB
1027 SKIP-IF-NOT-DEFINED OPTIONAL_SEND_DOCUMENT
1028
1029 NAME "Send-Document missing last-document: Send-Document Operation"
1030 OPERATION Send-Document
1031 GROUP operation-attributes-tag
1032 ATTR charset attributes-charset utf-8
1033 ATTR naturalLanguage attributes-natural-language en
1034 ATTR uri printer-uri $uri
1035 ATTR integer job-id $job-id
1036 ATTR name requesting-user-name $user
1037 ATTR name document-name $filename
1038 ATTR keyword compression none
1039 ATTR mimeMediaType document-format $filetype
1040 FILE $filename
1041
1042 STATUS client-error-bad-request
1043 }
1044
1045 {
1046 SKIP-IF-NOT-DEFINED OPTIONAL_CREATE_JOB
1047 SKIP-IF-NOT-DEFINED OPTIONAL_SEND_DOCUMENT
1048
1049 NAME "RFC 2911 section 3.3.3: Cancel-Job Operation"
1050 OPERATION Cancel-Job
1051 GROUP operation-attributes-tag
1052 ATTR charset attributes-charset utf-8
1053 ATTR naturalLanguage attributes-natural-language en
1054 ATTR uri printer-uri $uri
1055 ATTR integer job-id $job-id
1056 ATTR name requesting-user-name $user
1057
1058 STATUS successful-ok
1059 STATUS server-error-job-canceled
1060 }
1061
1062 # Test Create-Job and Send-URI operations
1063 #
1064 # Defined by: RFC 2911 section 3.2.4 and 3.3.2
1065 {
1066 SKIP-IF-NOT-DEFINED OPTIONAL_CREATE_JOB
1067 SKIP-IF-NOT-DEFINED OPTIONAL_SEND_URI
1068 SKIP-IF-NOT-DEFINED document-uri
1069
1070 NAME "RFC 2911 section 3.2.4: Create-Job Operation"
1071 OPERATION Create-Job
1072 GROUP operation-attributes-tag
1073 ATTR charset attributes-charset utf-8
1074 ATTR naturalLanguage attributes-natural-language en
1075 ATTR uri printer-uri $uri
1076 ATTR name requesting-user-name $user
1077 ATTR name job-name $filename
1078 ATTR boolean ipp-attribute-fidelity false
1079
1080 STATUS successful-ok
1081
1082 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1083 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1084 WITH-VALUE >0
1085 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1086 WITH-VALUE 3,4,5,6,7,8,9
1087 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1088 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1089 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1090 IN-GROUP job-attributes-tag WITH-VALUE >-1
1091 }
1092
1093 {
1094 SKIP-IF-NOT-DEFINED OPTIONAL_CREATE_JOB
1095 SKIP-IF-NOT-DEFINED OPTIONAL_SEND_URI
1096 SKIP-IF-NOT-DEFINED document-uri
1097
1098 NAME "RFC 2911 section 3.3.2: Send-URI Operation"
1099 OPERATION Send-URI
1100 GROUP operation-attributes-tag
1101 ATTR charset attributes-charset utf-8
1102 ATTR naturalLanguage attributes-natural-language en
1103 ATTR uri printer-uri $uri
1104 ATTR integer job-id $job-id
1105 ATTR name requesting-user-name $user
1106 ATTR boolean last-document true
1107 ATTR name document-name $filename
1108 ATTR keyword compression none
1109 ATTR uri document-uri $document-uri
1110
1111 STATUS successful-ok
1112 STATUS server-error-job-canceled
1113 }
1114
1115
1116 # Test Create-Job and Send-URI operations (bad URI)
1117 #
1118 # Defined by: RFC 2911 section 3.2.4 and 3.3.2
1119 {
1120 SKIP-IF-NOT-DEFINED OPTIONAL_CREATE_JOB
1121 SKIP-IF-NOT-DEFINED OPTIONAL_SEND_URI
1122
1123 NAME "Send-URI with bad URI: Create-Job Operation"
1124 OPERATION Create-Job
1125 GROUP operation-attributes-tag
1126 ATTR charset attributes-charset utf-8
1127 ATTR naturalLanguage attributes-natural-language en
1128 ATTR uri printer-uri $uri
1129 ATTR name requesting-user-name $user
1130 ATTR name job-name $filename
1131 ATTR boolean ipp-attribute-fidelity false
1132
1133 STATUS successful-ok
1134
1135 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1136 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1137 WITH-VALUE >0
1138 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1139 WITH-VALUE 3,4,5,6,7,8,9
1140 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1141 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1142 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1143 IN-GROUP job-attributes-tag WITH-VALUE >-1
1144 }
1145
1146 {
1147 SKIP-IF-NOT-DEFINED OPTIONAL_CREATE_JOB
1148 SKIP-IF-NOT-DEFINED OPTIONAL_SEND_URI
1149
1150 NAME "Send-URI with bad URI: Send-URI Operation (bad URI)"
1151 OPERATION Send-URI
1152 GROUP operation-attributes-tag
1153 ATTR charset attributes-charset utf-8
1154 ATTR naturalLanguage attributes-natural-language en
1155 ATTR uri printer-uri $uri
1156 ATTR integer job-id $job-id
1157 ATTR name requesting-user-name $user
1158 ATTR boolean last-document true
1159 ATTR name document-name $filename
1160 ATTR keyword compression none
1161 ATTR mimeMediaType document-format $filetype
1162 ATTR uri document-uri "bogus://bogus"
1163
1164 STATUS client-error-uri-scheme-not-supported
1165 }
1166
1167 {
1168 SKIP-IF-NOT-DEFINED OPTIONAL_CREATE_JOB
1169 SKIP-IF-NOT-DEFINED OPTIONAL_SEND_URI
1170
1171 NAME "Send-URI with bad URI: Cancel-Job Operation"
1172 OPERATION Cancel-Job
1173 GROUP operation-attributes-tag
1174 ATTR charset attributes-charset utf-8
1175 ATTR naturalLanguage attributes-natural-language en
1176 ATTR uri printer-uri $uri
1177 ATTR integer job-id $job-id
1178 ATTR name requesting-user-name $user
1179
1180 STATUS successful-ok
1181 STATUS server-error-job-canceled
1182 }
1183
1184
1185 # Test multiple copy output
1186 {
1187 SKIP-IF-NOT-DEFINED OPTIONAL_COPIES
1188
1189 NAME "Print-Job with copies"
1190 OPERATION Print-Job
1191 GROUP operation-attributes-tag
1192 ATTR charset attributes-charset utf-8
1193 ATTR naturalLanguage attributes-natural-language en
1194 ATTR uri printer-uri $uri
1195 ATTR name requesting-user-name $user
1196 ATTR name job-name $filename
1197 ATTR boolean ipp-attribute-fidelity false
1198 ATTR name document-name $filename
1199 ATTR keyword compression none
1200 ATTR mimeMediaType document-format $filetype
1201 GROUP job-attributes-tag
1202 ATTR integer copies 2
1203 FILE $filename
1204
1205 STATUS successful-ok
1206 STATUS client-error-document-format-not-supported
1207 STATUS server-error-job-canceled
1208 STATUS server-error-busy REPEAT-MATCH
1209
1210 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1211 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1212 WITH-VALUE >0
1213 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1214 WITH-VALUE 3,4,5,6,7,8,9
1215 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1216 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1217 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1218 IN-GROUP job-attributes-tag WITH-VALUE >-1
1219 }
1220
1221
1222 # Test PDF output
1223 {
1224 SKIP-IF-NOT-DEFINED OPTIONAL_PDF
1225 SKIP-IF-NOT-DEFINED OPTIONAL_A4_MEDIA
1226
1227 NAME "Print-Job with A4 PDF"
1228 OPERATION Print-Job
1229 GROUP operation-attributes-tag
1230 ATTR charset attributes-charset utf-8
1231 ATTR naturalLanguage attributes-natural-language en
1232 ATTR uri printer-uri $uri
1233 ATTR name requesting-user-name $user
1234 ATTR name job-name "A4 Test Document"
1235 ATTR boolean ipp-attribute-fidelity false
1236 ATTR name document-name document-a4.pdf
1237 ATTR keyword compression none
1238 ATTR mimeMediaType document-format application/pdf
1239 GROUP job-attributes-tag
1240 ATTR keyword media iso_a4_210x297mm
1241 FILE document-a4.pdf
1242
1243 STATUS successful-ok
1244 STATUS server-error-job-canceled
1245 STATUS server-error-busy REPEAT-MATCH
1246
1247 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1248 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1249 WITH-VALUE >0
1250 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1251 WITH-VALUE 3,4,5,6,7,8,9
1252 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1253 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1254 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1255 IN-GROUP job-attributes-tag WITH-VALUE >-1
1256 }
1257
1258 {
1259 SKIP-IF-NOT-DEFINED OPTIONAL_PDF
1260 SKIP-IF-NOT-DEFINED OPTIONAL_A4_MEDIA
1261 SKIP-IF-NOT-DEFINED OPTIONAL_DUPLEX
1262
1263 NAME "Print-Job with A4 PDF, Duplex"
1264 OPERATION Print-Job
1265 GROUP operation-attributes-tag
1266 ATTR charset attributes-charset utf-8
1267 ATTR naturalLanguage attributes-natural-language en
1268 ATTR uri printer-uri $uri
1269 ATTR name requesting-user-name $user
1270 ATTR name job-name "A4 Test Document, Duplex"
1271 ATTR boolean ipp-attribute-fidelity false
1272 ATTR name document-name document-a4.pdf
1273 ATTR keyword compression none
1274 ATTR mimeMediaType document-format application/pdf
1275 GROUP job-attributes-tag
1276 ATTR keyword media iso_a4_210x297mm
1277 ATTR keyword sides two-sided-long-edge
1278 FILE document-a4.pdf
1279
1280 STATUS successful-ok
1281 STATUS server-error-job-canceled
1282 STATUS server-error-busy REPEAT-MATCH
1283
1284 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1285 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1286 WITH-VALUE >0
1287 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1288 WITH-VALUE 3,4,5,6,7,8,9
1289 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1290 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1291 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1292 IN-GROUP job-attributes-tag WITH-VALUE >-1
1293 }
1294
1295 {
1296 SKIP-IF-NOT-DEFINED OPTIONAL_PDF
1297 SKIP-IF-NOT-DEFINED OPTIONAL_LETTER_MEDIA
1298
1299 NAME "Print-Job with US Letter PDF"
1300 OPERATION Print-Job
1301 GROUP operation-attributes-tag
1302 ATTR charset attributes-charset utf-8
1303 ATTR naturalLanguage attributes-natural-language en
1304 ATTR uri printer-uri $uri
1305 ATTR name requesting-user-name $user
1306 ATTR name job-name "US Letter Test Document"
1307 ATTR boolean ipp-attribute-fidelity false
1308 ATTR name document-name document-letter.pdf
1309 ATTR keyword compression none
1310 ATTR mimeMediaType document-format application/pdf
1311 GROUP job-attributes-tag
1312 ATTR keyword media na_letter_8.5x11in
1313 FILE document-letter.pdf
1314
1315 STATUS successful-ok
1316 STATUS server-error-job-canceled
1317 STATUS server-error-busy REPEAT-MATCH
1318
1319 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1320 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1321 WITH-VALUE >0
1322 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1323 WITH-VALUE 3,4,5,6,7,8,9
1324 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1325 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1326 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1327 IN-GROUP job-attributes-tag WITH-VALUE >-1
1328 }
1329
1330 {
1331 SKIP-IF-NOT-DEFINED OPTIONAL_PDF
1332 SKIP-IF-NOT-DEFINED OPTIONAL_LETTER_MEDIA
1333 SKIP-IF-NOT-DEFINED OPTIONAL_DUPLEX
1334
1335 NAME "Print-Job with US Letter PDF, Duplex"
1336 OPERATION Print-Job
1337 GROUP operation-attributes-tag
1338 ATTR charset attributes-charset utf-8
1339 ATTR naturalLanguage attributes-natural-language en
1340 ATTR uri printer-uri $uri
1341 ATTR name requesting-user-name $user
1342 ATTR name job-name "US Letter Test Document, Duplex"
1343 ATTR boolean ipp-attribute-fidelity false
1344 ATTR name document-name document-letter.pdf
1345 ATTR keyword compression none
1346 ATTR mimeMediaType document-format application/pdf
1347 GROUP job-attributes-tag
1348 ATTR keyword media na_letter_8.5x11in
1349 ATTR keyword sides two-sided-long-edge
1350 FILE document-letter.pdf
1351
1352 STATUS successful-ok
1353 STATUS server-error-job-canceled
1354 STATUS server-error-busy REPEAT-MATCH
1355
1356 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1357 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1358 WITH-VALUE >0
1359 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1360 WITH-VALUE 3,4,5,6,7,8,9
1361 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1362 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1363 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1364 IN-GROUP job-attributes-tag WITH-VALUE >-1
1365 }
1366
1367
1368 # Test PostScript output
1369 {
1370 SKIP-IF-NOT-DEFINED OPTIONAL_POSTSCRIPT
1371 SKIP-IF-NOT-DEFINED OPTIONAL_A4_MEDIA
1372
1373 NAME "Print-Job with A4 PostScript"
1374 OPERATION Print-Job
1375 GROUP operation-attributes-tag
1376 ATTR charset attributes-charset utf-8
1377 ATTR naturalLanguage attributes-natural-language en
1378 ATTR uri printer-uri $uri
1379 ATTR name requesting-user-name $user
1380 ATTR name job-name "A4 Test Document, Duplex"
1381 ATTR boolean ipp-attribute-fidelity false
1382 ATTR name document-name document-a4.ps
1383 ATTR keyword compression none
1384 ATTR mimeMediaType document-format application/postscript
1385 GROUP job-attributes-tag
1386 ATTR keyword media iso_a4_210x297mm
1387 FILE document-a4.ps
1388
1389 STATUS successful-ok
1390 STATUS server-error-job-canceled
1391 STATUS server-error-busy REPEAT-MATCH
1392
1393 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1394 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1395 WITH-VALUE >0
1396 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1397 WITH-VALUE 3,4,5,6,7,8,9
1398 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1399 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1400 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1401 IN-GROUP job-attributes-tag WITH-VALUE >-1
1402 }
1403
1404 {
1405 SKIP-IF-NOT-DEFINED OPTIONAL_POSTSCRIPT
1406 SKIP-IF-NOT-DEFINED OPTIONAL_A4_MEDIA
1407 SKIP-IF-NOT-DEFINED OPTIONAL_DUPLEX
1408
1409 NAME "Print-Job with A4 PostScript, Duplex"
1410 OPERATION Print-Job
1411 GROUP operation-attributes-tag
1412 ATTR charset attributes-charset utf-8
1413 ATTR naturalLanguage attributes-natural-language en
1414 ATTR uri printer-uri $uri
1415 ATTR name requesting-user-name $user
1416 ATTR name job-name "US Letter Test Document"
1417 ATTR boolean ipp-attribute-fidelity false
1418 ATTR name document-name document-a4.ps
1419 ATTR keyword compression none
1420 ATTR mimeMediaType document-format application/postscript
1421 GROUP job-attributes-tag
1422 ATTR keyword media iso_a4_210x297mm
1423 ATTR keyword sides two-sided-long-edge
1424 FILE document-a4.ps
1425
1426 STATUS successful-ok
1427 STATUS server-error-job-canceled
1428 STATUS server-error-busy REPEAT-MATCH
1429
1430 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1431 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1432 WITH-VALUE >0
1433 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1434 WITH-VALUE 3,4,5,6,7,8,9
1435 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1436 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1437 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1438 IN-GROUP job-attributes-tag WITH-VALUE >-1
1439 }
1440
1441 {
1442 SKIP-IF-NOT-DEFINED OPTIONAL_POSTSCRIPT
1443 SKIP-IF-NOT-DEFINED OPTIONAL_LETTER_MEDIA
1444
1445 NAME "Print-Job with US Letter PostScript"
1446 OPERATION Print-Job
1447 GROUP operation-attributes-tag
1448 ATTR charset attributes-charset utf-8
1449 ATTR naturalLanguage attributes-natural-language en
1450 ATTR uri printer-uri $uri
1451 ATTR name requesting-user-name $user
1452 ATTR name job-name "US Letter Test Document, Duplex"
1453 ATTR boolean ipp-attribute-fidelity false
1454 ATTR name document-name document-letter.ps
1455 ATTR keyword compression none
1456 ATTR mimeMediaType document-format application/postscript
1457 GROUP job-attributes-tag
1458 ATTR keyword media na_letter_8.5x11in
1459 FILE document-letter.ps
1460
1461 STATUS successful-ok
1462 STATUS server-error-job-canceled
1463 STATUS server-error-busy REPEAT-MATCH
1464
1465 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1466 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1467 WITH-VALUE >0
1468 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1469 WITH-VALUE 3,4,5,6,7,8,9
1470 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1471 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1472 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1473 IN-GROUP job-attributes-tag WITH-VALUE >-1
1474 }
1475
1476 {
1477 SKIP-IF-NOT-DEFINED OPTIONAL_POSTSCRIPT
1478 SKIP-IF-NOT-DEFINED OPTIONAL_LETTER_MEDIA
1479 SKIP-IF-NOT-DEFINED OPTIONAL_DUPLEX
1480
1481 NAME "Print-Job with US Letter PostScript, Duplex"
1482 OPERATION Print-Job
1483 GROUP operation-attributes-tag
1484 ATTR charset attributes-charset utf-8
1485 ATTR naturalLanguage attributes-natural-language en
1486 ATTR uri printer-uri $uri
1487 ATTR name requesting-user-name $user
1488 ATTR name job-name "A4 Test Document"
1489 ATTR boolean ipp-attribute-fidelity false
1490 ATTR name document-name document-letter.ps
1491 ATTR keyword compression none
1492 ATTR mimeMediaType document-format application/postscript
1493 GROUP job-attributes-tag
1494 ATTR keyword media na_letter_8.5x11in
1495 ATTR keyword sides two-sided-long-edge
1496 FILE document-letter.ps
1497
1498 STATUS successful-ok
1499 STATUS server-error-job-canceled
1500 STATUS server-error-busy REPEAT-MATCH
1501
1502 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1503 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1504 WITH-VALUE >0
1505 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1506 WITH-VALUE 3,4,5,6,7,8,9
1507 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1508 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1509 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1510 IN-GROUP job-attributes-tag WITH-VALUE >-1
1511 }
1512
1513
1514 # Test JPEG output
1515 {
1516 SKIP-IF-NOT-DEFINED OPTIONAL_JPEG
1517 SKIP-IF-NOT-DEFINED OPTIONAL_A4_MEDIA
1518
1519 NAME "Print-Job with Color JPEG on A4"
1520 OPERATION Print-Job
1521 GROUP operation-attributes-tag
1522 ATTR charset attributes-charset utf-8
1523 ATTR naturalLanguage attributes-natural-language en
1524 ATTR uri printer-uri $uri
1525 ATTR name requesting-user-name $user
1526 ATTR name job-name "Color JPEG on A4"
1527 ATTR boolean ipp-attribute-fidelity false
1528 ATTR name document-name color.jpg
1529 ATTR keyword compression none
1530 ATTR mimeMediaType document-format image/jpeg
1531 GROUP job-attributes-tag
1532 ATTR keyword media iso_a4_210x297mm
1533 FILE color.jpg
1534
1535 STATUS successful-ok
1536 STATUS server-error-job-canceled
1537 STATUS server-error-busy REPEAT-MATCH
1538
1539 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1540 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1541 WITH-VALUE >0
1542 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1543 WITH-VALUE 3,4,5,6,7,8,9
1544 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1545 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1546 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1547 IN-GROUP job-attributes-tag WITH-VALUE >-1
1548 }
1549
1550 {
1551 SKIP-IF-NOT-DEFINED OPTIONAL_JPEG
1552 SKIP-IF-NOT-DEFINED OPTIONAL_LETTER_MEDIA
1553
1554 NAME "Print-Job with Color JPEG on US Letter"
1555 OPERATION Print-Job
1556 GROUP operation-attributes-tag
1557 ATTR charset attributes-charset utf-8
1558 ATTR naturalLanguage attributes-natural-language en
1559 ATTR uri printer-uri $uri
1560 ATTR name requesting-user-name $user
1561 ATTR name job-name "Color JPEG on US Letter"
1562 ATTR boolean ipp-attribute-fidelity false
1563 ATTR name document-name color.jpg
1564 ATTR keyword compression none
1565 ATTR mimeMediaType document-format image/jpeg
1566 GROUP job-attributes-tag
1567 ATTR keyword media na_letter_8.5x11in
1568 FILE color.jpg
1569
1570 STATUS successful-ok
1571 STATUS server-error-job-canceled
1572 STATUS server-error-busy REPEAT-MATCH
1573
1574 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1575 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1576 WITH-VALUE >0
1577 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1578 WITH-VALUE 3,4,5,6,7,8,9
1579 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1580 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1581 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1582 IN-GROUP job-attributes-tag WITH-VALUE >-1
1583 }
1584
1585 {
1586 SKIP-IF-NOT-DEFINED OPTIONAL_JPEG
1587 SKIP-IF-NOT-DEFINED OPTIONAL_4X6_MEDIA
1588
1589 NAME "Print-Job with Color JPEG on 4x6"
1590 OPERATION Print-Job
1591 GROUP operation-attributes-tag
1592 ATTR charset attributes-charset utf-8
1593 ATTR naturalLanguage attributes-natural-language en
1594 ATTR uri printer-uri $uri
1595 ATTR name requesting-user-name $user
1596 ATTR name job-name "Color JPEG on 4x6"
1597 ATTR boolean ipp-attribute-fidelity false
1598 ATTR name document-name color.jpg
1599 ATTR keyword compression none
1600 ATTR mimeMediaType document-format image/jpeg
1601 GROUP job-attributes-tag
1602 ATTR keyword media na_index-4x6_4x6in
1603 FILE color.jpg
1604
1605 STATUS successful-ok
1606 STATUS server-error-job-canceled
1607 STATUS server-error-busy REPEAT-MATCH
1608
1609 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1610 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1611 WITH-VALUE >0
1612 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1613 WITH-VALUE 3,4,5,6,7,8,9
1614 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1615 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1616 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1617 IN-GROUP job-attributes-tag WITH-VALUE >-1
1618 }
1619
1620 {
1621 SKIP-IF-NOT-DEFINED OPTIONAL_JPEG
1622 SKIP-IF-NOT-DEFINED OPTIONAL_A4_MEDIA
1623
1624 NAME "Print-Job with Grayscale JPEG on A4"
1625 OPERATION Print-Job
1626 GROUP operation-attributes-tag
1627 ATTR charset attributes-charset utf-8
1628 ATTR naturalLanguage attributes-natural-language en
1629 ATTR uri printer-uri $uri
1630 ATTR name requesting-user-name $user
1631 ATTR name job-name "Grayscale JPEG on A4"
1632 ATTR boolean ipp-attribute-fidelity false
1633 ATTR name document-name gray.jpg
1634 ATTR keyword compression none
1635 ATTR mimeMediaType document-format image/jpeg
1636 GROUP job-attributes-tag
1637 ATTR keyword media iso_a4_210x297mm
1638 FILE gray.jpg
1639
1640 STATUS successful-ok
1641 STATUS server-error-job-canceled
1642 STATUS server-error-busy REPEAT-MATCH
1643
1644 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1645 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1646 WITH-VALUE >0
1647 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1648 WITH-VALUE 3,4,5,6,7,8,9
1649 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1650 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1651 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1652 IN-GROUP job-attributes-tag WITH-VALUE >-1
1653 }
1654
1655 {
1656 SKIP-IF-NOT-DEFINED OPTIONAL_JPEG
1657 SKIP-IF-NOT-DEFINED OPTIONAL_LETTER_MEDIA
1658
1659 NAME "Print-Job with Grayscale JPEG on US Letter"
1660 OPERATION Print-Job
1661 GROUP operation-attributes-tag
1662 ATTR charset attributes-charset utf-8
1663 ATTR naturalLanguage attributes-natural-language en
1664 ATTR uri printer-uri $uri
1665 ATTR name requesting-user-name $user
1666 ATTR name job-name "Grayscale JPEG on US Letter"
1667 ATTR boolean ipp-attribute-fidelity false
1668 ATTR name document-name gray.jpg
1669 ATTR keyword compression none
1670 ATTR mimeMediaType document-format image/jpeg
1671 GROUP job-attributes-tag
1672 ATTR keyword media na_letter_8.5x11in
1673 FILE gray.jpg
1674
1675 STATUS successful-ok
1676 STATUS server-error-job-canceled
1677 STATUS server-error-busy REPEAT-MATCH
1678
1679 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1680 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1681 WITH-VALUE >0
1682 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1683 WITH-VALUE 3,4,5,6,7,8,9
1684 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1685 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1686 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1687 IN-GROUP job-attributes-tag WITH-VALUE >-1
1688 }
1689
1690 {
1691 SKIP-IF-NOT-DEFINED OPTIONAL_JPEG
1692 SKIP-IF-NOT-DEFINED OPTIONAL_4X6_MEDIA
1693
1694 NAME "Print-Job with Grayscale JPEG on 4x6"
1695 OPERATION Print-Job
1696 GROUP operation-attributes-tag
1697 ATTR charset attributes-charset utf-8
1698 ATTR naturalLanguage attributes-natural-language en
1699 ATTR uri printer-uri $uri
1700 ATTR name requesting-user-name $user
1701 ATTR name job-name "Grayscale JPEG on 4x6"
1702 ATTR boolean ipp-attribute-fidelity false
1703 ATTR name document-name gray.jpg
1704 ATTR keyword compression none
1705 ATTR mimeMediaType document-format image/jpeg
1706 GROUP job-attributes-tag
1707 ATTR keyword media na_index-4x6_4x6in
1708 FILE gray.jpg
1709
1710 STATUS successful-ok
1711 STATUS server-error-job-canceled
1712 STATUS server-error-busy REPEAT-MATCH
1713
1714 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1715 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1716 WITH-VALUE >0
1717 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1718 WITH-VALUE 3,4,5,6,7,8,9
1719 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1720 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1721 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1722 IN-GROUP job-attributes-tag WITH-VALUE >-1
1723 }
1724
1725
1726 # Print-Job with job-sheets
1727 {
1728 SKIP-IF-NOT-DEFINED OPTIONAL_PDF
1729 SKIP-IF-NOT-DEFINED OPTIONAL_A4_MEDIA
1730 SKIP-IF-NOT-DEFINED OPTIONAL_STANDARD_SHEET
1731
1732 NAME "Print-Job with A4 PDF and Standard Sheet"
1733 OPERATION Print-Job
1734 GROUP operation-attributes-tag
1735 ATTR charset attributes-charset utf-8
1736 ATTR naturalLanguage attributes-natural-language en
1737 ATTR uri printer-uri $uri
1738 ATTR name requesting-user-name $user
1739 ATTR name job-name "A4 Test Document w/Standard Sheet"
1740 ATTR boolean ipp-attribute-fidelity false
1741 ATTR name document-name document-a4.pdf
1742 ATTR keyword compression none
1743 ATTR mimeMediaType document-format application/pdf
1744 GROUP job-attributes-tag
1745 ATTR keyword media iso_a4_210x297mm
1746 ATTR keyword job-sheets standard
1747 FILE document-a4.pdf
1748
1749 STATUS successful-ok
1750 STATUS server-error-job-canceled
1751 STATUS server-error-busy REPEAT-MATCH
1752
1753 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1754 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1755 WITH-VALUE >0
1756 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1757 WITH-VALUE 3,4,5,6,7,8,9
1758 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1759 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1760 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1761 IN-GROUP job-attributes-tag WITH-VALUE >-1
1762 }
1763
1764 {
1765 SKIP-IF-NOT-DEFINED OPTIONAL_PDF
1766 SKIP-IF-NOT-DEFINED OPTIONAL_LETTER_MEDIA
1767 SKIP-IF-NOT-DEFINED OPTIONAL_STANDARD_SHEET
1768
1769 NAME "Print-Job with US Letter PDF and Standard Sheet"
1770 OPERATION Print-Job
1771 GROUP operation-attributes-tag
1772 ATTR charset attributes-charset utf-8
1773 ATTR naturalLanguage attributes-natural-language en
1774 ATTR uri printer-uri $uri
1775 ATTR name requesting-user-name $user
1776 ATTR name job-name "US Letter Test Document w/Standard Sheet"
1777 ATTR boolean ipp-attribute-fidelity false
1778 ATTR name document-name document-a4.pdf
1779 ATTR keyword compression none
1780 ATTR mimeMediaType document-format application/pdf
1781 GROUP job-attributes-tag
1782 ATTR keyword media na_letter_8.5x11in
1783 ATTR keyword job-sheets standard
1784 FILE document-a4.pdf
1785
1786 STATUS successful-ok
1787 STATUS server-error-job-canceled
1788 STATUS server-error-busy REPEAT-MATCH
1789
1790 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1791 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1792 WITH-VALUE >0
1793 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1794 WITH-VALUE 3,4,5,6,7,8,9
1795 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1796 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1797 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1798 IN-GROUP job-attributes-tag WITH-VALUE >-1
1799 }
1800
1801 {
1802 SKIP-IF-NOT-DEFINED OPTIONAL_POSTSCRIPT
1803 SKIP-IF-NOT-DEFINED OPTIONAL_A4_MEDIA
1804 SKIP-IF-NOT-DEFINED OPTIONAL_STANDARD_SHEET
1805
1806 NAME "Print-Job with A4 PDF and Standard Sheet"
1807 OPERATION Print-Job
1808 GROUP operation-attributes-tag
1809 ATTR charset attributes-charset utf-8
1810 ATTR naturalLanguage attributes-natural-language en
1811 ATTR uri printer-uri $uri
1812 ATTR name requesting-user-name $user
1813 ATTR name job-name "A4 Test Document w/Standard Sheet"
1814 ATTR boolean ipp-attribute-fidelity false
1815 ATTR name document-name document-a4.ps
1816 ATTR keyword compression none
1817 ATTR mimeMediaType document-format application/postscript
1818 GROUP job-attributes-tag
1819 ATTR keyword media iso_a4_210x297mm
1820 ATTR keyword job-sheets standard
1821 FILE document-a4.ps
1822
1823 STATUS successful-ok
1824 STATUS server-error-job-canceled
1825 STATUS server-error-busy REPEAT-MATCH
1826
1827 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1828 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1829 WITH-VALUE >0
1830 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1831 WITH-VALUE 3,4,5,6,7,8,9
1832 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1833 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1834 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1835 IN-GROUP job-attributes-tag WITH-VALUE >-1
1836 }
1837
1838 {
1839 SKIP-IF-NOT-DEFINED OPTIONAL_POSTSCRIPT
1840 SKIP-IF-NOT-DEFINED OPTIONAL_LETTER_MEDIA
1841 SKIP-IF-NOT-DEFINED OPTIONAL_STANDARD_SHEET
1842
1843 NAME "Print-Job with US Letter PDF and Standard Sheet"
1844 OPERATION Print-Job
1845 GROUP operation-attributes-tag
1846 ATTR charset attributes-charset utf-8
1847 ATTR naturalLanguage attributes-natural-language en
1848 ATTR uri printer-uri $uri
1849 ATTR name requesting-user-name $user
1850 ATTR name job-name "US Letter Test Document w/Standard Sheet"
1851 ATTR boolean ipp-attribute-fidelity false
1852 ATTR name document-name document-a4.ps
1853 ATTR keyword compression none
1854 ATTR mimeMediaType document-format application/postscript
1855 GROUP job-attributes-tag
1856 ATTR keyword media na_letter_8.5x11in
1857 ATTR keyword job-sheets standard
1858 FILE document-a4.ps
1859
1860 STATUS successful-ok
1861 STATUS server-error-job-canceled
1862 STATUS server-error-busy REPEAT-MATCH
1863
1864 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1865 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1866 WITH-VALUE >0
1867 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1868 WITH-VALUE 3,4,5,6,7,8,9
1869 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1870 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1871 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1872 IN-GROUP job-attributes-tag WITH-VALUE >-1
1873 }
1874
1875
1876 # Test number-up output
1877 {
1878 SKIP-IF-NOT-DEFINED OPTIONAL_PDF
1879 SKIP-IF-NOT-DEFINED OPTIONAL_A4_MEDIA
1880 SKIP-IF-NOT-DEFINED OPTIONAL_2UP
1881
1882 NAME "Print-Job with A4 PDF, 2-Up"
1883 OPERATION Print-Job
1884 GROUP operation-attributes-tag
1885 ATTR charset attributes-charset utf-8
1886 ATTR naturalLanguage attributes-natural-language en
1887 ATTR uri printer-uri $uri
1888 ATTR name requesting-user-name $user
1889 ATTR name job-name "A4 Test Document, 2-Up"
1890 ATTR boolean ipp-attribute-fidelity false
1891 ATTR name document-name document-a4.pdf
1892 ATTR keyword compression none
1893 ATTR mimeMediaType document-format application/pdf
1894 GROUP job-attributes-tag
1895 ATTR keyword media iso_a4_210x297mm
1896 ATTR integer number-up 2
1897 FILE document-a4.pdf
1898
1899 STATUS successful-ok
1900 STATUS server-error-job-canceled
1901 STATUS server-error-busy REPEAT-MATCH
1902
1903 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1904 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1905 WITH-VALUE >0
1906 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1907 WITH-VALUE 3,4,5,6,7,8,9
1908 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1909 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1910 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1911 IN-GROUP job-attributes-tag WITH-VALUE >-1
1912 }
1913
1914 {
1915 SKIP-IF-NOT-DEFINED OPTIONAL_PDF
1916 SKIP-IF-NOT-DEFINED OPTIONAL_LETTER_MEDIA
1917 SKIP-IF-NOT-DEFINED OPTIONAL_2UP
1918
1919 NAME "Print-Job with US Letter PDF, 2-Up"
1920 OPERATION Print-Job
1921 GROUP operation-attributes-tag
1922 ATTR charset attributes-charset utf-8
1923 ATTR naturalLanguage attributes-natural-language en
1924 ATTR uri printer-uri $uri
1925 ATTR name requesting-user-name $user
1926 ATTR name job-name "US Letter Test Document, 2-Up"
1927 ATTR boolean ipp-attribute-fidelity false
1928 ATTR name document-name document-letter.pdf
1929 ATTR keyword compression none
1930 ATTR mimeMediaType document-format application/pdf
1931 GROUP job-attributes-tag
1932 ATTR keyword media na_letter_8.5x11in
1933 ATTR integer number-up 2
1934 FILE document-letter.pdf
1935
1936 STATUS successful-ok
1937 STATUS server-error-job-canceled
1938 STATUS server-error-busy REPEAT-MATCH
1939
1940 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1941 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1942 WITH-VALUE >0
1943 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1944 WITH-VALUE 3,4,5,6,7,8,9
1945 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1946 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1947 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1948 IN-GROUP job-attributes-tag WITH-VALUE >-1
1949 }
1950
1951 {
1952 SKIP-IF-NOT-DEFINED OPTIONAL_POSTSCRIPT
1953 SKIP-IF-NOT-DEFINED OPTIONAL_A4_MEDIA
1954 SKIP-IF-NOT-DEFINED OPTIONAL_2UP
1955
1956 NAME "Print-Job with A4 PDF, 2-Up"
1957 OPERATION Print-Job
1958 GROUP operation-attributes-tag
1959 ATTR charset attributes-charset utf-8
1960 ATTR naturalLanguage attributes-natural-language en
1961 ATTR uri printer-uri $uri
1962 ATTR name requesting-user-name $user
1963 ATTR name job-name "A4 Test Document, 2-Up"
1964 ATTR boolean ipp-attribute-fidelity false
1965 ATTR name document-name document-a4.ps
1966 ATTR keyword compression none
1967 ATTR mimeMediaType document-format application/postscript
1968 GROUP job-attributes-tag
1969 ATTR keyword media iso_a4_210x297mm
1970 ATTR integer number-up 2
1971 FILE document-a4.ps
1972
1973 STATUS successful-ok
1974 STATUS server-error-job-canceled
1975 STATUS server-error-busy REPEAT-MATCH
1976
1977 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
1978 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
1979 WITH-VALUE >0
1980 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
1981 WITH-VALUE 3,4,5,6,7,8,9
1982 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
1983 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
1984 EXPECT ?number-of-intervening-jobs OF-TYPE integer
1985 IN-GROUP job-attributes-tag WITH-VALUE >-1
1986 }
1987
1988 {
1989 SKIP-IF-NOT-DEFINED OPTIONAL_POSTSCRIPT
1990 SKIP-IF-NOT-DEFINED OPTIONAL_LETTER_MEDIA
1991 SKIP-IF-NOT-DEFINED OPTIONAL_2UP
1992
1993 NAME "Print-Job with US Letter PDF, 2-Up"
1994 OPERATION Print-Job
1995 GROUP operation-attributes-tag
1996 ATTR charset attributes-charset utf-8
1997 ATTR naturalLanguage attributes-natural-language en
1998 ATTR uri printer-uri $uri
1999 ATTR name requesting-user-name $user
2000 ATTR name job-name "US Letter Test Document, 2-Up"
2001 ATTR boolean ipp-attribute-fidelity false
2002 ATTR name document-name document-letter.ps
2003 ATTR keyword compression none
2004 ATTR mimeMediaType document-format application/postscript
2005 GROUP job-attributes-tag
2006 ATTR keyword media na_letter_8.5x11in
2007 ATTR integer number-up 2
2008 FILE document-letter.ps
2009
2010 STATUS successful-ok
2011 STATUS server-error-job-canceled
2012 STATUS server-error-busy REPEAT-MATCH
2013
2014 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
2015 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
2016 WITH-VALUE >0
2017 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
2018 WITH-VALUE 3,4,5,6,7,8,9
2019 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
2020 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
2021 EXPECT ?number-of-intervening-jobs OF-TYPE integer
2022 IN-GROUP job-attributes-tag WITH-VALUE >-1
2023 }
2024
2025
2026 # Test output with print-quality...
2027 {
2028 SKIP-IF-NOT-DEFINED OPTIONAL_JPEG
2029 SKIP-IF-NOT-DEFINED OPTIONAL_4X6_MEDIA
2030 SKIP-IF-NOT-DEFINED OPTIONAL_DRAFT_QUALITY
2031
2032 NAME "Print-Job with JPEG on 4x6, Draft Quality"
2033 OPERATION Print-Job
2034 GROUP operation-attributes-tag
2035 ATTR charset attributes-charset utf-8
2036 ATTR naturalLanguage attributes-natural-language en
2037 ATTR uri printer-uri $uri
2038 ATTR name requesting-user-name $user
2039 ATTR name job-name "4x6 Color JPEG, Draft Quality"
2040 ATTR boolean ipp-attribute-fidelity false
2041 ATTR name document-name color.jpg
2042 ATTR keyword compression none
2043 ATTR mimeMediaType document-format image/jpeg
2044 GROUP job-attributes-tag
2045 ATTR keyword media na_index-4x6_4x6in
2046 ATTR enum print-quality 3
2047 FILE color.jpeg
2048
2049 STATUS successful-ok
2050 STATUS server-error-job-canceled
2051 STATUS server-error-busy REPEAT-MATCH
2052
2053 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
2054 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
2055 WITH-VALUE >0
2056 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
2057 WITH-VALUE 3,4,5,6,7,8,9
2058 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
2059 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
2060 EXPECT ?number-of-intervening-jobs OF-TYPE integer
2061 IN-GROUP job-attributes-tag WITH-VALUE >-1
2062 }
2063
2064 {
2065 SKIP-IF-NOT-DEFINED OPTIONAL_JPEG
2066 SKIP-IF-NOT-DEFINED OPTIONAL_4X6_MEDIA
2067 SKIP-IF-NOT-DEFINED OPTIONAL_NORMAL_QUALITY
2068
2069 NAME "Print-Job with JPEG on 4x6, Normal Quality"
2070 OPERATION Print-Job
2071 GROUP operation-attributes-tag
2072 ATTR charset attributes-charset utf-8
2073 ATTR naturalLanguage attributes-natural-language en
2074 ATTR uri printer-uri $uri
2075 ATTR name requesting-user-name $user
2076 ATTR name job-name "4x6 Color JPEG, Normal Quality"
2077 ATTR boolean ipp-attribute-fidelity false
2078 ATTR name document-name color.jpg
2079 ATTR keyword compression none
2080 ATTR mimeMediaType document-format image/jpeg
2081 GROUP job-attributes-tag
2082 ATTR keyword media na_index-4x6_4x6in
2083 ATTR enum print-quality 4
2084 FILE color.jpeg
2085
2086 STATUS successful-ok
2087 STATUS server-error-job-canceled
2088 STATUS server-error-busy REPEAT-MATCH
2089
2090 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
2091 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
2092 WITH-VALUE >0
2093 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
2094 WITH-VALUE 3,4,5,6,7,8,9
2095 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
2096 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
2097 EXPECT ?number-of-intervening-jobs OF-TYPE integer
2098 IN-GROUP job-attributes-tag WITH-VALUE >-1
2099 }
2100
2101 {
2102 SKIP-IF-NOT-DEFINED OPTIONAL_JPEG
2103 SKIP-IF-NOT-DEFINED OPTIONAL_4X6_MEDIA
2104 SKIP-IF-NOT-DEFINED OPTIONAL_HIGH_QUALITY
2105
2106 NAME "Print-Job with JPEG on 4x6, High Quality"
2107 OPERATION Print-Job
2108 GROUP operation-attributes-tag
2109 ATTR charset attributes-charset utf-8
2110 ATTR naturalLanguage attributes-natural-language en
2111 ATTR uri printer-uri $uri
2112 ATTR name requesting-user-name $user
2113 ATTR name job-name "4x6 Color JPEG, High Quality"
2114 ATTR boolean ipp-attribute-fidelity false
2115 ATTR name document-name color.jpg
2116 ATTR keyword compression none
2117 ATTR mimeMediaType document-format image/jpeg
2118 GROUP job-attributes-tag
2119 ATTR keyword media na_index-4x6_4x6in
2120 ATTR enum print-quality 5
2121 FILE color.jpeg
2122
2123 STATUS successful-ok
2124 STATUS server-error-job-canceled
2125 STATUS server-error-busy REPEAT-MATCH
2126
2127 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
2128 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
2129 WITH-VALUE >0
2130 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
2131 WITH-VALUE 3,4,5,6,7,8,9
2132 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
2133 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
2134 EXPECT ?number-of-intervening-jobs OF-TYPE integer
2135 IN-GROUP job-attributes-tag WITH-VALUE >-1
2136 }
2137
2138 {
2139 SKIP-IF-NOT-DEFINED OPTIONAL_PDF
2140 SKIP-IF-NOT-DEFINED OPTIONAL_A4_MEDIA
2141 SKIP-IF-NOT-DEFINED OPTIONAL_DRAFT_QUALITY
2142
2143 NAME "Print-Job with A4 PDF, Draft Quality"
2144 OPERATION Print-Job
2145 GROUP operation-attributes-tag
2146 ATTR charset attributes-charset utf-8
2147 ATTR naturalLanguage attributes-natural-language en
2148 ATTR uri printer-uri $uri
2149 ATTR name requesting-user-name $user
2150 ATTR name job-name "A4 Test Document, 2-Up"
2151 ATTR boolean ipp-attribute-fidelity false
2152 ATTR name document-name document-a4.pdf
2153 ATTR keyword compression none
2154 ATTR mimeMediaType document-format application/pdf
2155 GROUP job-attributes-tag
2156 ATTR keyword media iso_a4_210x297mm
2157 ATTR enum print-quality 3
2158 FILE document-a4.pdf
2159
2160 STATUS successful-ok
2161 STATUS server-error-job-canceled
2162 STATUS server-error-busy REPEAT-MATCH
2163
2164 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
2165 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
2166 WITH-VALUE >0
2167 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
2168 WITH-VALUE 3,4,5,6,7,8,9
2169 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
2170 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
2171 EXPECT ?number-of-intervening-jobs OF-TYPE integer
2172 IN-GROUP job-attributes-tag WITH-VALUE >-1
2173 }
2174
2175 {
2176 SKIP-IF-NOT-DEFINED OPTIONAL_PDF
2177 SKIP-IF-NOT-DEFINED OPTIONAL_LETTER_MEDIA
2178 SKIP-IF-NOT-DEFINED OPTIONAL_DRAFT_QUALITY
2179
2180 NAME "Print-Job with US Letter PDF, Draft Quality"
2181 OPERATION Print-Job
2182 GROUP operation-attributes-tag
2183 ATTR charset attributes-charset utf-8
2184 ATTR naturalLanguage attributes-natural-language en
2185 ATTR uri printer-uri $uri
2186 ATTR name requesting-user-name $user
2187 ATTR name job-name "US Letter Test Document, 2-Up"
2188 ATTR boolean ipp-attribute-fidelity false
2189 ATTR name document-name document-letter.pdf
2190 ATTR keyword compression none
2191 ATTR mimeMediaType document-format application/pdf
2192 GROUP job-attributes-tag
2193 ATTR keyword media na_letter_8.5x11in
2194 ATTR enum print-quality 3
2195 FILE document-letter.pdf
2196
2197 STATUS successful-ok
2198 STATUS server-error-job-canceled
2199 STATUS server-error-busy REPEAT-MATCH
2200
2201 EXPECT job-uri OF-TYPE uri COUNT 1 IN-GROUP job-attributes-tag WITH-VALUE "$IPP_URI_SCHEME"
2202 EXPECT job-id OF-TYPE integer COUNT 1 IN-GROUP job-attributes-tag
2203 WITH-VALUE >0
2204 EXPECT job-state OF-TYPE enum COUNT 1 IN-GROUP job-attributes-tag
2205 WITH-VALUE 3,4,5,6,7,8,9
2206 EXPECT job-state-reasons OF-TYPE keyword IN-GROUP job-attributes-tag
2207 EXPECT ?job-state-message OF-TYPE text IN-GROUP job-attributes-tag
2208 EXPECT ?number-of-intervening-jobs OF-TYPE integer
2209 IN-GROUP job-attributes-tag WITH-VALUE >-1
2210 }
2211
2212
2213 #
2214 # End of "$Id$".
2215 #