[IMP] l10n_tr_nilvera_einvoice: add tests#228010
Conversation
|
@SaddemAmine @alialfie cherrypicking of pull request #216179 failed. stdout: Either perform the forward-port manually (and push to this branch, proceeding as usual) or close this PR (maybe?). In the former case, you may want to edit this PR message as well. More info at https://github.com/odoo/odoo/wiki/Mergebot#forward-port |
b7be7da to
7114b49
Compare
| if modules.module.current_test: | ||
| return |
There was a problem hiding this comment.
In the previous impl we disregarded the compute method verifying the partners' statuses. I think it's better to revert this to prevent regression. It's unfortunately not a "test" since we check this during the setUpClass but I think it's good enough.
7114b49 to
238070d
Compare
f47f8c1 to
5e33ae7
Compare
|
@SaddemAmine @alialfie this forward port of #216179 is awaiting action (not merged or closed). |
3324864 to
41336c5
Compare
|
In this FW we adapt the changes in original PR to work with l10n_tr_nilvera_einvoice_extended since both modules utilize the same common file. We also integrate already existing tests from the previous implementation that test multicurrency scenarios and earchive exports. The aforementioned will not be backported to 17.0 following the stable policy currently only allowing critical changes to be committed in unsupported versions. |
41336c5 to
a4108aa
Compare
7dbc962 to
8c35921
Compare
|
The test partners VAT change is needed to comply with the base_vat TR format even though, AFAIK, we noticed that Nilvera itself (which communicates straight with the Turkish government) can have VAT numbers that follow other formats. |
|
As discussed, a new PR #229724 has been created to remove the file for the skipped tests that were conflicting with this FW port. This FW port will now only be concerned with the mocking part for testing which should be in a new file specifically for mocking API calls. @SaddemAmine Please update the PR and the commit message accordingly :D |
8c35921 to
ddd3686
Compare
f6f44cb to
1ef717d
Compare
|
To clarify how this FW is being handled: first, we decided to keep the check in _compute_nilvera_customer_status_and_alias_id within l10n_tr_nilvera_einvoice and add an additional safeguard to make sure the compute still runs when mocking Nilvera endpoints and executing the TestTRNilveraEInvoice suite. Second, as Ali mentioned, the tests introduced here are strictly about ensuring proper interaction with Nilvera. All XML generation tests are now handled in l10n_tr_nilvera_einvoice_extended and should be merged back into l10n_tr_nilvera_einvoice as of saas~18.4. |
1ef717d to
0320c71
Compare
FlorianGilbert
left a comment
There was a problem hiding this comment.
Can we r+ now? @alialfie @SaddemAmine
|
@FlorianGilbert Yup |
|
robodoo r+ |
|
robodoo r- @SaddemAmine You forgot to change the file name, no? |
0320c71 to
a47d6b4
Compare
|
Yuup, completely slipped my mind |
Currently we're lacking tests for the Nilvera API integration. This commit adds a test suite that primarily focuses on testing that. Task ID: 4655864 X-original-commit: 2dfcbe5
a47d6b4 to
86f5603
Compare
Currently we're lacking tests for the Nilvera API integration. This commit adds a test suite that primarily focuses on testing that. Task ID: 4655864 closes odoo/odoo#228010 X-original-commit: 2dfcbe53c80d2d8fe5b6d9828eea90a1d214c2e4 Signed-off-by: Ali Alfie (alal) <alal@odoo.com>
Currently we're lacking tests for the Nilvera API integration. This commit adds a test suite that primarily focuses on testing that. Task ID: 4655864 closes odoo#228010 X-original-commit: 2dfcbe5 Signed-off-by: Ali Alfie (alal) <alal@odoo.com>
Currently we're lacking tests for the Nilvera API integration. This commit adds a test suite that primarily focuses on testing that. Task ID: 4655864 closes odoo#228010 X-original-commit: 2dfcbe5 Signed-off-by: Ali Alfie (alal) <alal@odoo.com>

Currently we're lacking tests for the Nilvera API integration. This
commit adds a test suite that primarily focuses on testing that.
Task ID: 4655864
Forward-Port-Of: #216179