Initial commit

This commit is contained in:
gsinghpal
2026-02-22 01:22:18 -05:00
commit 5200d5baf0
2394 changed files with 386834 additions and 0 deletions

View File

@@ -0,0 +1 @@
from . import test_print_product_label

View File

@@ -0,0 +1,31 @@
from odoo.tests.common import TransactionCase
from odoo.tools import test_reports
from odoo.tests import tagged
@tagged('post_install', '-at_install', 'garazd_product_label')
class TestPrintProductLabel(TransactionCase):
def setUp(self):
super(TestPrintProductLabel, self).setUp()
self.product_chair = self.env.ref('product.product_product_12')
self.product_drawer = self.env.ref('product.product_product_27')
def test_print_wizard(self):
ctx = {
'active_model': 'product.product',
'default_product_product_ids': [
self.product_chair.id,
self.product_drawer.id,
],
}
wizard = self.env['print.product.label'].with_context(**ctx).create({})
self.assertEqual(len(wizard.label_ids), 2)
test_reports.try_report(
self.env.cr,
self.env.uid,
'garazd_product_label.report_product_label_57x35_template',
ids=wizard.label_ids.ids,
our_module='garazd_product_label'
)