URL: https://github.com/freeipa/freeipa/pull/448
Title: #448: Tests: Basic coverage with tree root domain

martbab commented:
"""
If you look at the test cases (e.g. test_login_ipa-user, test_login_ad_user, 
test_login_subdomain_user are the 'best: examples) you can see that the 
function body is the same code copy-pasted with slight alterations so that it 
works for the new case. Your patch adds a *fourth* level of copy-pasta to the 
code, which is something that grieves me greatly.

Clearly, you can group the common code into a private method that can be only 
called with the use-case specific parameters for each test case. Or you can 
expand the existing mixing hierarchy to achieve this. Then it would also be 
simpler to extend the test cases for tree-root domains.
"""

See the full comment at 
https://github.com/freeipa/freeipa/pull/448#issuecomment-278939703
-- 
Manage your subscription for the Freeipa-devel mailing list:
https://www.redhat.com/mailman/listinfo/freeipa-devel
Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code

Reply via email to