NAME

Test::Async::Event – collection of standard events

SYNOPSIS

use Test::Async::Event;

test-bundle MyBundle {
    method foo(Str:D $message) is test-tool {
        self.send-test: Event::Ok, :$message
    }
}

DESCRIPTION

General information about Test::Async event management can be found in Test::Async::Manual.

Events are objects of classes derived from Event class. This module defines events used by the core. In general, all event classes can be conventionally split into the following groups:

EXPORTED CLASSES

Class Event

The base event class.

Attributes

Methods

Class Event::Report

Is Event.

Base class for events carrying a text message of any kind.

Attributes

Class Event::Command

Is Event.

Base class of commanding events. Test::Async::Hub handles them specially.

Attributes

Class Event::Test

Is Event::Report

Base class for events reporting test outcomes.

Attributes

Class Event::Terminate

Is Event.

This is the only kind of event which Term::Async::Aggregator role cares about. It tells the event loop to pull any remaining events from the queue and dispatch them immediately. Then it fulfills event's promise.

Attributes

Class Event::Telemetry

Is Event

Under development yet.

Class Event::Plan

Is Event::Report

Plan reporting event. Emitted when a suite gets to know the number of tests to be done.

Attributes

Class Event::Diag

Is Event::Report.

Carries a diagnostics message. See diag in Test::Async::Base.

Class Event::Ok

Is Event::Test.

Test passed.

Class Event::NotOk

Is Event::Test.

Test flunked.

Class Event::Skip

Is Event::Test.

Test skipped.

Class Event::DoneTesting

Is Event::Report.

Emitted when testing is completely done.

Class Event::BailOut

Is Event::Report

Emitted when test suite is about to bail out.

Command event classes Event::Cmd::*

A bundle of events used internally for commands. See Test::Async::Hub and possibly other modules. The set of command events is not standartized and subject for changes.

SEE ALSO

Test::Async::Manual, Test::Async::Aggregator, Test::Async::Hub

AUTHOR

Vadim Belman <vrurg@cpan.org>