#include <TestResult.h>
Public Types | |
| typedef QList< QPointer< TestResult > > | List |
| enum | Status { Unknown = 0, Pass, Fail, NotTested } |
Public Member Functions | |
| QString | asSerialized () const |
| ASTItem * | astTree () const |
| QString | comment () const |
| Patternist::Item::List | items () const |
| Patternist::Message::List | messages () const |
| void | setComment (const QString &comment) |
| Status | status () const |
| TestResult (const QString &testName, const Status status, ASTItem *astTree, const Patternist::Message::List &errors, const Patternist::Item::List &items, const QString &serialized) | |
| void | toXML (XMLWriter &receiver) const |
| virtual | ~TestResult () |
Static Public Member Functions | |
| static QString | displayName (const TestResult::Status status) |
| static Status | statusFromString (const QString &string) |
This information TestResult houses is:
Definition at line 47 of file TestResult.h.
| typedef QList<QPointer<TestResult> > KXQTS::TestResult::List |
A list of TestResult instances.
Definition at line 78 of file TestResult.h.
| Unknown | Used when the status is unknown. |
| Pass | The test case passed. |
| Fail | The test case failed. |
| NotTested | The test was not run. Similar to "SKIP". |
Definition at line 52 of file TestResult.h.
| TestResult::TestResult | ( | const QString & | testName, | |
| const Status | status, | |||
| ASTItem * | astTree, | |||
| const Patternist::Message::List & | errors, | |||
| const Patternist::Item::List & | items, | |||
| const QString & | serialized | |||
| ) |
Constructs a TestResult.
| testName | the name of the test. For example, Literal-001. | |
| astTree | may be null, signalling no AST being available, or point to one. | |
| status | the result status of running the test-case. Whether the test-case passed or failed, and so forth. | |
| errors | the errors and warnings that were reported while running the test-case | |
| items | the XDM items that were outputted, if any | |
| serialized | the output when serialized |
Definition at line 58 of file TestResult.cpp.
| QString TestResult::asSerialized | ( | ) | const |
Definition at line 122 of file TestResult.cpp.
Referenced by KXQTS::TestResultView::displayTestResult().
Here is the caller graph for this function:

| QString TestResult::displayName | ( | const TestResult::Status | status | ) | [static] |
status, as per the anonymous type inside the type test-case, in XQTSResult.xsd. For example, if status is NotTested, is "not tested" returned. Definition at line 25 of file TestResult.cpp.
References Fail, NotTested, Pass, and Unknown.
Referenced by KXQTS::XQTSTestCase::data(), KXQTS::TestResultView::displayTestResult(), and toXML().
Here is the caller graph for this function:

| void TestResult::toXML | ( | XMLWriter & | receiver | ) | const |
Serializes itself to receiver, into a test-case element, as per XQTSResult.xsd.
Definition at line 79 of file TestResult.cpp.
References displayName(), KXQTS::XMLWriter::endElement(), and KXQTS::XMLWriter::startElement().
Here is the call graph for this function:

1.5.1