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

TestReporter should not be initialiased with test case list and status #95

Open
lczub opened this issue Nov 5, 2017 · 0 comments
Open

Comments

@lczub
Copy link
Owner

lczub commented Nov 5, 2017

Pull request #94 added the class TestReporter and MixinSubclasses to automatically create missing test plans, platforms and builds, when reporting test case results.

Current behaviour is, that the list of test cases and status must be set during the TestReport init . So if different stati should be reported for the same platform, build, plan combination, separate report instances are needed. Sample

    tls = testlink.TestLinkHelper('https://testlink.corp.com/testlink/lib/api/xmlrpc/v1/xmlrpc.php',
                                  'devkeyabc123').connect(testlink.TestlinkAPIClient)
    tgr_p = TestGenReporter(tls, ['TEST-123', 'TEST-456'], testprojectname='MANUALLY_MADE_PROJECT',
                                  testplanname='generated', platformname='gend', buildname='8.fake', status='p')
    tgr_p.report()                      
    tgr_f = TestGenReporter(tls, ['TEST-321', 'TEST-654'], testprojectname='MANUALLY_MADE_PROJECT',
                                 testplanname='generated', platformname='gend', buildname='8.fake', status='f')
    tgr_f.report()   

A better approach would be, that the init do not need the test case list and status and this can be set with the report() call. Suggestion

    tls = testlink.TestLinkHelper('https://testlink.corp.com/testlink/lib/api/xmlrpc/v1/xmlrpc.php',
                                  'devkeyabc123').connect(testlink.TestlinkAPIClient)
    tgr = TestGenReporter(tls, testprojectname='MANUALLY_MADE_PROJECT',
                                  testplanname='generated', platformname='gend', buildname='8.fake')
    tgr.report(['TEST-123', 'TEST-456'], status='p')                      
    tgr.report(['TEST-321', 'TEST-654'], status='f') 
@lczub lczub added this to the v0.6.5 milestone Nov 5, 2017
@lczub lczub removed this from the v0.6.5 milestone May 18, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant