NAME

Test::Smoke::Poster::Base - Base class for the posters to CoreSmokeDB.

DESCRIPTION

Provide general methods for the poster subclasses.

Test::Smoke::Poster::Base->new(%arguments);

Arguments

Named.

smokedb_url => $some_url
ddir => $smoke_directory
jsnfile => $json_file (mktest.jsn)
v => $verbosity

Returns

An instance of the class.

Exceptions

None.

$poster->agent_string()

Class and intstance method.

Arguments

None.

Returns

sprintf "Test::Smoke/%s (%s)", $Test::Smoke::VERSION, $class;

Exceptions

None.

$poster->get_json()

Arguments

None.

Returns

The json string that was stored in $ddir/$jsnfile.

Exceptions

File I/O.

$poster->json_filename()

Returns the the fully qualified file name of the jsonfile.

$poster->post()

Post the JSON report to CoreSmokeDB.

Arguments

None.

Returns

The id of the CoreSmokeDB report on success.

Exceptions

HTTP or Test::Smoke::Gateway-application errors.

$poster->queue_this_report()

Use the new queue mechanism to try to send this report before the next smoke run.

$poster->_post_data()

Abstract method that should be implemented by the subclass.

Arguments

None.

Returns

The body of the response.

$poster->_post_data_api()

Abstract method that should be implemented by the subclass.

Arguments

None.

Returns

The body of the response.

$poster->_process_post_result($response_body)

Process the result of the POST action to CoreSmokeDB.

Arguments

Positional.

$response_body (the raw JSON string send by CoreSmokeDB)

Returns

The id of the report on success, undef on failure.

COPYRIGHT

(c) 2002-2013, Abe Timmerman <abeltje@cpan.org> All rights reserved.

With contributions from Jarkko Hietaniemi, Merijn Brand, Campo Weijerman, Alan Burlison, Allen Smith, Alain Barbet, Dominic Dunlop, Rich Rauenzahn, David Cantrell.

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

See:

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.