OpenTAP 9.24
API Reference
Public Member Functions | List of all members
OpenTap.IArtifactListener Interface Reference

Defines the interface for IArtifactListeners. Artifacts are generated by the test plan and may be any kind of file. The artifacts are published sequentially with the results. More...

Inheritance diagram for OpenTap.IArtifactListener:
OpenTap.TestPlanRunSummaryListener

Public Member Functions

void OnArtifactPublished (TestRun run, Stream artifactStream, string artifactName)
 Invoked when an artifact is published. Note the artifactStream MUST be disposed after use. The artifact may be a FileStream, in which case it can be used as such. More...
 

Detailed Description

Defines the interface for IArtifactListeners. Artifacts are generated by the test plan and may be any kind of file. The artifacts are published sequentially with the results.

Member Function Documentation

◆ OnArtifactPublished()

void OpenTap.IArtifactListener.OnArtifactPublished ( TestRun  run,
Stream  artifactStream,
string  artifactName 
)

Invoked when an artifact is published. Note the artifactStream MUST be disposed after use. The artifact may be a FileStream, in which case it can be used as such.

Parameters
runMay be a TestPlanRun or TestStepRun depending on how the artifact is published. If it is published with a TestStepRun it means it belongs to that specific step. If its a TestStepRun, TestStepRunCompleted has not been called for that step run.
artifactStreamThe stream containing the artifact data.
artifactNameThe name of the artifact. e.g results.csv

Implemented in OpenTap.TestPlanRunSummaryListener.

OpenTAP 9.24 API built Tue Apr 30 2024 13:44:41