Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FW][FIX] hr_holidays: make test_current_leave_status deterministic #122826

Conversation

fw-bot
Copy link
Contributor

@fw-bot fw-bot commented May 30, 2023

The test_current_leave_status checks the correct implementation of different hr.leave computed fields. To do this, a leave is created, during the test. The test fails however, when the employee is not supposed to work during the leave period, which can happen when running the test on certain days. The test is made deterministic again by adding the number_of_days field to the dict. As this is a stored field, the created leave entry will be considered valid.

Closes #119591

Forward-Port-Of: #121533

The test_current_leave_status checks the correct implementation of different
hr.leave computed fields. To do this, a leave is created, during the test. The
test fails however, when the employee is not supposed to work during the leave
period, which can happen when running the test on certain days. The test is
made deterministic again by adding the number_of_days field to the dict. As
this is a stored field, the created leave entry will be considered valid.

X-original-commit: a1dffd3
@robodoo
Copy link
Contributor

robodoo commented May 30, 2023

@fw-bot
Copy link
Contributor Author

fw-bot commented May 30, 2023

This PR targets 15.0 and is part of the forward-port chain. Further PRs will be created up to master.

More info at https://github.com/odoo/odoo/wiki/Mergebot#forward-port

@robodoo robodoo added the forwardport This PR was created by @fw-bot label May 30, 2023
@C3POdoo C3POdoo added the RD research & development, internal work label May 30, 2023
robodoo pushed a commit that referenced this pull request May 30, 2023
The test_current_leave_status checks the correct implementation of different
hr.leave computed fields. To do this, a leave is created, during the test. The
test fails however, when the employee is not supposed to work during the leave
period, which can happen when running the test on certain days. The test is
made deterministic again by adding the number_of_days field to the dict. As
this is a stored field, the created leave entry will be considered valid.

closes #122826

X-original-commit: a1dffd3
Signed-off-by: Kevin Baptiste <kba@odoo.com>
@robodoo robodoo temporarily deployed to merge May 30, 2023 11:20 Inactive
@robodoo robodoo closed this May 30, 2023
@fw-bot fw-bot deleted the 15.0-14.0-hr_holidays-indeterministic_test-tdc-yC6L-fw branch June 13, 2023 11:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
forwardport This PR was created by @fw-bot RD research & development, internal work
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants