Uploaded image for project: 'Code Tools'
  1. Code Tools
  2. CODETOOLS-7900808

need a way to get data on interface methods coverage

    XMLWordPrintable

Details

    • 1.2
    • generic
    • generic
    • Verified

    Description



      Name: inR10064 Date: 02/27/2003



      For now JCov do not provide convenient mode for gathering data about invocations
      of interface methods. The same seems to be correct for abstract methods of abstract
      classes.

      In some areas of test development significant part of tested API consists of
      interfaces not pure classes. Usually some factory methods are used to get
      implementation of these interfaces to operate with help of the interface methods
      so that exact implementing classes remain unknown. A factory can also choose
      the implementation classes dynamicly. So the tests for such API should
      only use interface methods in the code. So numbers of interface method invocations
      within test code will give much more precise information about coverage of API
      than data about execution of RI methods implementing the API interface methods
      which is provided by JCov.

      The example is DOM level 2 in JAXP 1.1 and JDK 1.4 (the org.w3c.dom
      package) where 17 interfaces provide methods to traverse and manipulate parsed
      XML document represented in a tree of objects. Common test (application) gets
      reference to root node (instance of the org.w3c.dom.Document interface) with some
      method of the javax.xml.parsers.DocumentBuilder class and after that the test only
      invokes methods of interfaces defined in DOM API. In DOM some interfaces extend
      other interfaces in the API so given a particular execution of RI method it's
      impossible to know method of which interface/superinterface is actually checked.


      ======================================================================

      Attachments

        Activity

          People

            lmesnik Leonid Mesnik
            klooney Kevin Looney (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: