mirror of
https://github.com/OCA/report-print-send.git
synced 2025-02-16 07:11:31 +02:00
[PORT] Printer Tray to V11
This commit is contained in:
@@ -7,7 +7,7 @@ from odoo.tests.common import TransactionCase
|
||||
|
||||
class TestIrActionsReportXml(TransactionCase):
|
||||
def test_onchange_printer_tray_id_empty(self):
|
||||
action = self.env['ir.actions.report.xml'].new(
|
||||
action = self.env['ir.actions.report'].new(
|
||||
{'printer_tray_id': False})
|
||||
action.onchange_printing_printer_id()
|
||||
self.assertFalse(action.printer_tray_id)
|
||||
@@ -31,7 +31,7 @@ class TestIrActionsReportXml(TransactionCase):
|
||||
'printer_id': printer.id,
|
||||
})
|
||||
|
||||
action = self.env['ir.actions.report.xml'].new(
|
||||
action = self.env['ir.actions.report'].new(
|
||||
{'printer_tray_id': tray.id})
|
||||
self.assertEqual(action.printer_tray_id, tray)
|
||||
action.onchange_printing_printer_id()
|
||||
|
||||
@@ -104,7 +104,7 @@ class TestPrintingPrinter(TransactionCase):
|
||||
"""
|
||||
It should generate the right options dictionnary
|
||||
"""
|
||||
report = self.env['ir.actions.report.xml'].search([], limit=1)
|
||||
report = self.env['ir.actions.report'].search([], limit=1)
|
||||
action = self.env['printing.report.xml.action'].create({
|
||||
'user_id': self.env.user.id,
|
||||
'report_id': report.id,
|
||||
|
||||
@@ -36,7 +36,7 @@ class TestPrintingTray(TransactionCase):
|
||||
|
||||
def test_report_behaviour(self):
|
||||
""" It should add the selected tray in the report data """
|
||||
ir_report = self.env['ir.actions.report.xml'].search([], limit=1)
|
||||
ir_report = self.env['ir.actions.report'].search([], limit=1)
|
||||
report = self.env['printing.report.xml.action'].create({
|
||||
'user_id': self.env.user.id,
|
||||
'report_id': ir_report.id,
|
||||
|
||||
Reference in New Issue
Block a user