Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Tracking evolution of the ApplicationValidatorTest with the refactoring
- Issue: I tried to use mocking, but I have found that it doesn't work well and even if, it would not cover too much of the implementation. - dol and ejb-container have too many relations, in fact the abstraction was unusable and worthless (and even undocumented). - I can create mocks for interfaces but I can't use them for validator. - I can create half-initialized mock of the abstract class, but it throws exceptions which take too much time to investigate and finally I find that the issue is the mock, not the code I wanted to test. - Same would apply for custom implementations (like is the only one, ejb-container) - too much details matter. - In practice: dol should have much better API, OR all descriptors and nodes whould move to DOL. They can be extended and used in ejb-container, but must have some basic consistent meaningful implementation. - So I do some basic steps forward now. - Final result: test covering bug we have noticed in logs + the fix not breaking anything else. Side effect result: easier future changes. Signed-off-by: David Matějček <david.matejcek@omnifish.ee>
- Loading branch information