2f829b0e28 [REF] crm: cleanup test environment to prepare changes in assignment process
This commit contains two main preparatory changes in tests

  * 1) lead_month_count will be changed to count lost lead as well. So
    archiving leads before running the test doesn't reset the counter.
    Lead needs to be unlinked in order to make tests reproducible;

  * 2) assertMemberAssign checked the validity of the team domain. Normally
    all lead assigned to the member should match the domain of its team.
    This assert is not always verified since we force the team after a
    merge of duplicated leads. Final merged lead may not match team domain
    anymore as final properties depend on all merged leads.

Some tests are also added :

  * add tests for master lead team_id and user_id values when merging leads
    in assign process;
  * add tests using email_normalized check in duplicate finding to ensure that
    normalized emails are used for duplicates and not only exact match;
  * add tests for won / lost inclusion in ``_get_lead_duplicates``, as well
    as different between probability=100 and stage.is_won = True . This is
    going to change in upcoming commits, hence some test to highlight it;
  * add tests counting existing leads for assignment purpose;
  * add tests for assignment_max maximum leads allocation as well as max=0
    meaning salesperson is opt-outed from assign;
  * add tests for default user / team / stage computation for leads;
  * add tests about leads taken into account in assign process (currently
    failing with won unassigned leads);

We also add some flush to ensure some fields notably related to probabilities
are flushed before counting queries.

LINKS

Task ID-2444908 (assign fixes)
Task ID-2489951 (assign process improvements)
COM PR odoo/odoo#70172

X-original-commit: bd3444085974f4e12287c2f5da4fb33308cd6180
Co-authored-by: Thibault François <tfr@odoo.com>
Co-authored-by: Thibault Delavallée <tde@odoo.com>
2021-05-12 14:00:58 +00:00
2021-05-07 15:13:07 +00:00
…
…
…
2019-11-08 11:24:04 +00:00
2020-09-28 14:07:25 +00:00

Build Status Tech Doc Help Nightly Builds

Odoo

Odoo is a suite of web based open source business apps.

The main Odoo Apps include an Open Source CRM, Website Builder, eCommerce, Warehouse Management, Project Management, Billing & Accounting, Point of Sale, Human Resources, Marketing, Manufacturing, ...

Odoo Apps can be used as stand-alone applications, but they also integrate seamlessly so you get a full-featured Open Source ERP when you install several Apps.

Getting started with Odoo

For a standard installation please follow the Setup instructions from the documentation.

To learn the software, we recommend the Odoo eLearning, or Scale-up, the business game. Developers can start with the developer tutorials

S
Description
No description provided
Readme LGPL-3.0
3.4 GiB
Languages
Python 49.6%
JavaScript 47.8%
SCSS 2%
CSS 0.3%
HTML 0.2%