Project and Services mailing list archives

project@odoo-community.org

Avatar

Re: [OCA/project] project_task_scheduling: Module for automatic task planning (#419)

by Nikul Chaudhary <notifications@github.com> - 27/09/2018 06:56:38

@nikul-serpentcs commented on this pull request.

Small Change


In project_task_employee/tests/test_project_task.py:

> @@ -0,0 +1,46 @@
+# Copyright 2018 Tecnativa - Ernesto Tejeda
+# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
+from odoo.tests.common import TransactionCase
+
+
+class TestProjectTask(TransactionCase):
+    def setUp(self):
+        super(TestProjectTask, self).setUp()
+
+        self.task_3 = self.env['project.task'].browse(

@ernestotejeda IMO Add one variable and use this obj self.env['project.task'].

Ex: self.project_task_obj = self.env['project.task']


In project_task_employee/tests/test_project_task.py:

> +
+class TestProjectTask(TransactionCase):
+    def setUp(self):
+        super(TestProjectTask, self).setUp()
+
+        self.task_3 = self.env['project.task'].browse(
+            self.ref("project_task_employee.restricted_task_3"))
+        self.task_2 = self.env['project.task'].browse(
+            self.ref("project_task_employee.restricted_task_2"))
+        self.task_7 = self.env['project.task'].browse(
+            self.ref("project_task_employee.restricted_task_7"))
+        self.task_1 = self.env['project.task'].browse(
+            self.ref("project_task_employee.restricted_task_1"))
+
+    def test_employee_domain_ids(self):
+        jth = self.env['hr.employee'].browse(self.ref("hr.employee_jth"))

@ernestotejeda same as here


You are receiving this because you are on a team that was mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.