Openbravo Issue Tracking System - Openbravo ERP |
| View Issue Details |
|
| ID | Project | Category | View Status | Date Submitted | Last Update |
| 0045839 | Openbravo ERP | A. Platform | public | 2021-02-03 16:05 | 2022-02-01 14:44 |
|
| Reporter | alostale | |
| Assigned To | Triage Platform Base | |
| Priority | normal | Severity | minor | Reproducibility | have not tried |
| Status | new | Resolution | open | |
| Platform | | OS | 5 | OS Version | |
| Product Version | | |
| Target Version | | Fixed in Version | | |
| Merge Request Status | |
| Review Assigned To | |
| OBNetwork customer | OBPS |
| Web browser | |
| Modules | Core |
| Support ticket | |
| Regression level | |
| Regression date | |
| Regression introduced in release | |
| Regression introduced by commit | |
| Triggers an Emergency Pack | No |
|
| Summary | 0045839: disabled jUnit tests execute @After method but not @Before |
| Description | When a jUnit test is disabled by config [1], its @After method is executed but not its @Before one. This can be problematic if @After assumes @Before was executed.
The reason is the test is disabled in OBBaseTest @Before method execute assumeTrue(false), which causes the rest of @Before methods in the hierarchy not to be executed, but all @After methods are executed.
[1] http://wiki.openbravo.com/wiki/How_to_create_JUnit_testcases#Skipping_test_cases [^] |
| Steps To Reproduce | Find here [1] a simplified stack that reproduces the problem.
[1] https://gitlab.com/alo-issues/openbravo/-/snippets/2070275 [^] |
| Proposed Solution | To be consistent with how tests are disabled programmatically with assumptions, both should be executed. |
| Additional Information | |
| Tags | No tags attached. |
| Relationships | | related to | defect | 0045840 | | new | Triage Platform Base | Openbravo ERP | MisfirePolicyTest fails when it's disabled by configuration | | related to | defect | 0048493 | | closed | Triage Omni WMS | Modules | NPE executing tests if OBDOReservationTest is disabled |
|
| Attached Files | |
|
| Issue History |
| Date Modified | Username | Field | Change |
| 2021-02-03 16:05 | alostale | New Issue | |
| 2021-02-03 16:05 | alostale | Assigned To | => platform |
| 2021-02-03 16:05 | alostale | OBNetwork customer | => No |
| 2021-02-03 16:05 | alostale | Modules | => Core |
| 2021-02-03 16:05 | alostale | Triggers an Emergency Pack | => No |
| 2021-02-03 16:07 | shuehner | Issue Monitored: shuehner | |
| 2021-02-03 16:12 | alostale | Relationship added | related to 0045840 |
| 2022-01-25 11:47 | martinsdan | Issue Monitored: martinsdan | |
| 2022-01-25 13:11 | martinsdan | OBNetwork customer | No => OBPS |
| 2022-01-27 14:57 | alostale | Relationship added | related to 0048493 |
| 2022-02-01 08:07 | alostale | Assigned To | platform => Triage Platform Base |
| 2022-02-01 14:44 | hgbot | Note Added: 0134712 | |