18.0 migration survey result mail#230
Open
layadelcarmen wants to merge 15 commits into
Open
Conversation
Currently translated at 100.0% (15 of 15 strings) Translation: survey-15.0/survey-15.0-survey_result_mail Translate-URL: https://translation.odoo-community.org/projects/survey-15-0/survey-15-0-survey_result_mail/it/
- noupdate template - set default sender - fix extra comments responses to show up in simple render - debug field for basic html render TT40979
We need to group the mail condition so it doesn't send the mail when the last one is true. TT48644
Format dates in the basic html render result. TT55323
added 3 commits
June 18, 2026 12:27
Add 9 new tests covering previously untested branches in models/survey_user_input.py: - _mark_done: send_result_mail=False, no partner/email, custom template - _build_answers_html: char_box, date, datetime, multiple_choice, matrix, and skipped-line exclusion - _compute_survey_result: basic mode and bootstrap mode
- test_build_answers_html_skipped_excluded: pass answer_type=False alongside skipped=True to satisfy the _check_answer_type_skipped constraint which rejects having both a non-null answer_type and skipped=True on the same line - test_compute_survey_result_bootstrap_mode: mock _render_user_input to avoid rendering web.layout which requires an HTTP request context unavailable in unit tests; still verifies the bootstrap branch calls the right method
Odoo 18 raises ValueError if a compute method does not assign the field for every record. Add else branch to _compute_survey_result so unknown modes fall back to False instead of leaving the field unset. Add test_compute_survey_result_bootstrap_mode: mock ir.ui.view._render_template instead of _render_user_input so the full method body is covered. Add test_compute_survey_result_unknown_mode to cover the new else branch.
Author
|
@benbrich Check this out when you have a chance |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.