http://defect.opensolaris.org/bz/show_bug.cgi?id=19226

           Summary: tests need improvements/should not depend on execution
                    order
    Classification: Development
           Product: opengrok
           Version: unspecified
          Platform: ANY/Generic
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P3
         Component: tests
        AssignedTo: [email protected]
        ReportedBy: [email protected]
                CC: [email protected]


Several tests especially with singletons seem to assume an/rely on test
execution order, which in turn results sometimes in test failures/errors
(e.g. HistoryGuruTest.bug16465() ).

Also it seems, that many tests succeed just by accident because one or more
test(s) have been run before, which aligned things ...
RuntimeEnvironmentTest is an outstanding example for this.

Perhaps it is better to give these singletons a package scoped destroy()
method, which resets the internal instance var back to null ... Also one could
use introspection in the test to "reset" the current instance/send it to
nirwana to get a virgin instance for the test.

Last but not least, if not obvious, it should be documented, what is tested or
why the test is needed. E.g. RuntimeEnvironmentTest.testRegister() doesn't test
RuntimeEnvironment.register(), but something different and thus should be
documented ...

-- 
Configure bugmail: http://defect.opensolaris.org/bz/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
_______________________________________________
opengrok-dev mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/opengrok-dev

Reply via email to