Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.atlassian.bamboo.builder
Class AntXmlTestResultsParser

    java.lang.Object
      com.atlassian.bamboo.configuration.DefaultContentHandler
          com.atlassian.bamboo.builder.AntXmlTestResultsParser

All Implemented Interfaces:
  ContentHandler

    public class AntXmlTestResultsParser

extends DefaultContentHandler

This class extracts the interesting test information from the ant test results.

Field Summary

Fields inherited from class com.atlassian.bamboo.configuration.DefaultContentHandler
`DEFAULT_PARSER`

Constructor Summary
`AntXmlTestResultsParser()`

Method Summary
`List` | `getFailedTests()` How many failed tests did the last parsed test report contain?
`int` | `getNumberOfErrors()` How many errors did we find in ihe last parsed test report
`int` | `getNumberOfTests()` How many tests did the last parsed test report contain?
`List` | `getSuccessfulTests()` How many successful tests did the last parsed test report contain?
`String` | `getSystemErr()`
`String` | `getSystemOut()`
`boolean` | `hasErrors()` Does the last parsed test report have any errors?
`void` | `parse(InputStream myTestInputStream)`
`void` | `parse(InputStream errorReportStream, File myAntTestResultsFile)` Extract unit test results from the given maven test report.

Methods inherited from class com.atlassian.bamboo.configuration.DefaultContentHandler
`characters, endDocument, endElement, endPrefixMapping, ignorableWhitespace, processingInstruction, registerElementParser, setDocumentLocator, skippedEntity, startDocument, startElement, startPrefixMapping`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### AntXmlTestResultsParser

    public AntXmlTestResultsParser()

Method Detail

### parse

    public void parse(InputStream errorReportStream,
                      File myAntTestResultsFile)

  Extract unit test results from the given maven test report.

  Parameters:
    `errorReportStream` - Maven test report (XML) stream
    `myAntTestResultsFile` - file. Ussed being read. used for debuggging.

### hasErrors

    public boolean hasErrors()

  Does the last parsed test report have any errors?

  Returns:
    true if we have detected errors, false otherwise

### getNumberOfErrors

    public int getNumberOfErrors()

  How many errors did we find in ihe last parsed test report

  Returns:
    number of errors found

### getNumberOfTests

    public int getNumberOfTests()

  How many tests did the last parsed test report contain?

  Returns:
    The number of tests

### getSuccessfulTests

    public List getSuccessfulTests()

  How many successful tests did the last parsed test report contain?

  Returns:
    The number of successful tests

### getFailedTests

    public List getFailedTests()

  How many failed tests did the last parsed test report contain?

  Returns:
    The number of failed tests

### getSystemOut

    public String getSystemOut()

### getSystemErr

    public String getSystemErr()

### parse

    public void parse(InputStream myTestInputStream)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2006 Atlassian Software Systems. All Rights Reserved.