Skip to content
This repository has been archived by the owner on Dec 29, 2022. It is now read-only.

Added Legal Paper cloud print test #132

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions _ticket.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,10 @@ class GCPConstants(object):
A4_HEIGHT = 297000
A4_WIDTH = 210000

# Legal Paper size in microns
LEGAL_HEIGHT = 356000
LEGAL_WIDTH = 216000

#
# CJS (Cloud Job State) constants
#
Expand Down
21 changes: 20 additions & 1 deletion testcert.py
Original file line number Diff line number Diff line change
Expand Up @@ -5400,7 +5400,26 @@ def test_48_CloudPrintMarginsOptions(self):
prompt += 'If the margins are not correct, fail this test.'
self.waitAndManualPass(test_id, test_name, output,
verification_prompt=prompt)


def test_49_CloudPrintMediaSizeSelectLegal(self):
"""Verify cloud printing with media size option."""
#test_id = 'c8de872f-49bd-45b7-9623-8db0861aed35'
test_name = 'GCP.PageSizeLegal'
_logger.info('Testing the selection of Legal media size.')
PromptAndWaitForUserAction('Load printer with Legal size paper. '
'Select return when ready.')

self.cjt.AddSizeOption(GCPConstants.LEGAL_HEIGHT, GCPConstants.LEGAL_WIDTH)
output = self.submit(_device.dev_id, Constants.IMAGES['PNG1'], test_id,
test_name, self.cjt)
try:
self.assertTrue(output['success'])
except AssertionError:
notes = 'Error selecting Legal media size.'
self.LogTest(test_id, test_name, 'Failed', notes)
raise
else:
self.waitAndManualPass(test_id, test_name, output)

if __name__ == '__main__':
runner = unittest.TextTestRunner(verbosity=2)
Expand Down