diff options
| author | Raphael Collet <rco@openerp.com> | 2011-12-13 12:14:11 +0100 |
|---|---|---|
| committer | Raphael Collet <rco@openerp.com> | 2011-12-13 12:14:11 +0100 |
| commit | 0e70f2c8d842f27174248898984a99a9925da62f (patch) | |
| tree | ab16227ba3fc7308270fdc62cf4ac584491fe4c4 /addons/project_long_term/test/task_process.yml | |
| parent | 6d2b3545773ce354721a313db74a3ef5b47fa2d9 (diff) | |
| parent | 5f583e89c05851337b3827abbb8cc5c3ecb98440 (diff) | |
[MERGE] project_long_term: improve tests
bzr revid: rco@openerp.com-20111213111411-pdnftk1kjnjbrzdo
Diffstat (limited to 'addons/project_long_term/test/task_process.yml')
| -rw-r--r-- | addons/project_long_term/test/task_process.yml | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/addons/project_long_term/test/task_process.yml b/addons/project_long_term/test/task_process.yml new file mode 100644 index 00000000000..64ecef73476 --- /dev/null +++ b/addons/project_long_term/test/task_process.yml @@ -0,0 +1,19 @@ +- + I create a record to compute the tasks of project. +- + !record {model: project.compute.tasks, id: project_compute_tasks0}: + project_id: project.project_integrate_openerp +- + I compute and shedule the tasks. +- + !python {model: project.compute.tasks}: | + self.compute_date(cr, uid, [ref("project_compute_tasks0")]) +- + Check if tasks scheduled, check that either of task's start_date, end_date and user_id is not null +- + !python {model: project.project}: | + prj = self.browse(cr, uid, [ref("project.project_integrate_openerp")])[0] + for task in prj.tasks: + if task.state in ('done','cancelled'): + continue + assert task.user_id and task.date_start and task.date_end, "Project tasks not scheduled" |
