NAME
Myriad::Test - a collection of helpers to test microservices.
SYNOPSIS
use Test::Myriad;
my $mock_service = add_service(name => 'mocked_service');
DESCRIPTION
A mini utility to help developers testing myriad services.
it can create completely fake services or mock already existing ones.
It uses the Myriad::Transport::Memory by default to change that you can set the environment variable MYRIAD_TEST_TRANSPORT
Methods
add_service
Adds a service to the test environment the service can be an already existing service or totally a new mocked one.
it takes one of the following params:
service
- A package name for an existing service.name
- A Perl package name that will hold the new mocked service.
ready
Returns a Future indicate that test env is ready to be used.
at the moment it is just a shortcut for Myriad run_future.
instance
Returns the Myriad instance we are using
AUTHOR
Deriv Group Services Ltd. DERIV@cpan.org
.
See "CONTRIBUTORS" in Myriad for full details.
LICENSE
Copyright Deriv Group Services Ltd 2020. Licensed under the same terms as Perl itself.