-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'feature/304_forward_case_and_step_results' into feature…
…/247-sakuli-se
- Loading branch information
Showing
179 changed files
with
2,979 additions
and
1,239 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 3 additions & 3 deletions
6
src/common/src/main/resources/org/sakuli/common/config/templates/check_mk/main.twig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
{% spaceless %} | ||
{% import 'error_message_creator.twig' as errorMessageCreator %} | ||
<<<local>>>$newline$ | ||
{% include 'performance_data.twig' %} | ||
{% include 'short_summary.twig' %} | ||
{% include 'detailed_summary.twig' %} | ||
{% include 'performance_data.twig' with { testsuite: testDataEntity}%} | ||
{% include 'short_summary.twig' with { testsuite: testDataEntity}%} | ||
{% include 'detailed_summary.twig' with { testsuite: testDataEntity}%} | ||
$newline$ | ||
{% endspaceless %} |
22 changes: 9 additions & 13 deletions
22
...ommon/src/main/resources/org/sakuli/common/config/templates/gearman/case_information.twig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,10 @@ | ||
{% for testCaseId, testCase in testsuite.testCasesAsSortedSet %} | ||
{% if (testCase.state.warning || testCase.state.critical || testCase.state.error) %} | ||
, case "{{ testCase.name }}"$whitespace$ | ||
{% if (testCase.state.error) %} | ||
EXCEPTION: {{ errorMessageCreator.exceptionMessageTestCase(testCase) }} | ||
{% else %} | ||
{% if (testCase.state.critical) %} | ||
over runtime ( {{ testCase.duration | number_format(2, '.') }}s/crit at {{ testCase.criticalTime }}s) | ||
{% else %} | ||
over runtime ( {{ testCase.duration | number_format(2, '.') }}s/warn at {{ testCase.warningTime }}s) | ||
{% endif %} | ||
{% endif %} | ||
{% if (testCase.state.warning || testCase.state.critical || testCase.state.error) %} | ||
, case "{{ testCase.id }}"$whitespace$ | ||
{% if (testCase.state.error) %} | ||
EXCEPTION: {{ errorMessageCreator.exceptionMessageTestCase(testCase) }} | ||
{% elseif (testCase.state.critical) %} | ||
over runtime ( {{ testCase.duration | number_format(2, '.') }}s/crit at {{ testCase.criticalTime }}s) | ||
{% else %} | ||
over runtime ( {{ testCase.duration | number_format(2, '.') }}s/warn at {{ testCase.warningTime }}s) | ||
{% endif %} | ||
{% endfor %} | ||
{% endif %} |
86 changes: 8 additions & 78 deletions
86
...ommon/src/main/resources/org/sakuli/common/config/templates/gearman/detailed_summary.twig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,78 +1,8 @@ | ||
{# This template renders the detailed summary for the current test suite. #} | ||
{% include 'detailed_summary_css_styles.twig' %} | ||
<table style="border-collapse: collapse;"> | ||
<tr valign="top"> | ||
<td class="service{{ getOutputState(testsuite.state) }}"> | ||
{{ getOutputState(testsuite.state).shortState }} Sakuli suite "{{ testsuite.id }}"$whitespace$ | ||
{% if (testsuite.state.error) %} | ||
{% else %} | ||
{{ testsuite.state.nagiosStateDescription }}$whitespace$ | ||
{% endif %} | ||
{% if (testsuite.state.ok) %} | ||
({{ testsuite.duration | number_format(2, '.') }}s)$whitespace$ | ||
{% elseif (testsuite.state.name == 'WARNING_IN_SUITE') %} | ||
({{ testsuite.duration | number_format(2, '.') }}s/warn at {{ testsuite.warningTime }}s)$whitespace$ | ||
{% elseif (testsuite.state.name == 'CRITICAL_IN_SUITE') %} | ||
({{ testsuite.duration | number_format(2, '.') }}s/crit at {{ testsuite.criticalTime }}s)$whitespace$ | ||
{% elseif (testsuite.state.name == 'WARNING_IN_STEP') %} | ||
{% for testCaseId, testCase in testsuite.testCasesAsSortedSet %} | ||
{% if (testCase.state.warningInStep) %} | ||
{% for testStep in testCase.steps %} | ||
{% if (testStep.state.warning) %} | ||
, step "{{ testStep.id }}" over runtime ({{ testStep.duration | number_format(2, '.') }}s/warn at {{ testStep.warningTime }}s) | ||
{% endif %} | ||
{% endfor %} | ||
{% endif %} | ||
{% endfor %} | ||
{% elseif (testsuite.state.name == 'WARNING_IN_CASE') %} | ||
{% for testCaseId, testCase in testsuite.testCasesAsSortedSet %} | ||
{% if (testCase.state.warning) %} | ||
, case "{{ testCase.id }}" over runtime ({{ testCase.duration | number_format(2, '.') }}s/warn at {{ testCase.warningTime }}s) | ||
{% endif %} | ||
{% endfor %} | ||
{% elseif (testsuite.state.name == 'CRITICAL_IN_CASE') %} | ||
{% for testCaseId, testCase in testsuite.testCasesAsSortedSet %} | ||
{% if (testCase.state.critical) %} | ||
, case "{{ testCase.id }}" over runtime ({{ testCase.duration | number_format(2, '.') }}s/crit at {{ testCase.criticalTime }}s) | ||
{% endif %} | ||
{% endfor %} | ||
{% endif %} | ||
{% if (testsuite.state.error) %} | ||
({{ testsuite.duration | number_format(2, '.') }}s)$whitespace$ | ||
{{ testsuite.state.nagiosStateDescription }}:$whitespace$ | ||
{{ errorMessageCreator.exceptionMessageTestSuite(testsuite) }}.$whitespace$ | ||
{% endif %} | ||
. (Last suite run:$whitespace$ | ||
{% if (empty(testsuite.stopDate)) %} | ||
xx | ||
{% else %} | ||
{{ testsuite.stopDate|date("dd.MM.YY HH:mm:ss") }} | ||
{% endif %}) | ||
{% include 'exception_screenshot.twig' with { testDataEntity: testsuite } %} | ||
</td> | ||
</tr> | ||
{% for testCase in testsuite.testCasesAsSortedSet %} | ||
<tr valign="top"> | ||
<td class="service{{ getOutputState(testCase.state) }}"> | ||
{{ getOutputState(testCase.state).shortState }} case "{{ testCase.id }}"$whitespace$ | ||
{% if (testCase.state.ok) %} | ||
ran in {{ testCase.duration | number_format(2, '.') }}s - {{ testCase.state.nagiosStateDescription }} | ||
{% elseif (testCase.state.warning) %} | ||
over runtime ({{ testCase.duration | number_format(2, '.') }}s/warn at {{ testCase.warningTime }}s) | ||
{% include 'step_information.twig' with { testCase: testCase } %}$whitespace$ | ||
{% elseif (testCase.state.critical) %} | ||
{% set errorMessage = errorMessageCreator.exceptionMessageTestCase(testCase) %} | ||
{% if (empty(errorMessage)) %} | ||
over runtime ({{ testCase.duration | number_format(2, '.') }}s/crit at {{ testCase.criticalTime }}s) | ||
{% else %} | ||
EXCEPTION: {{ errorMessageCreator.exceptionMessageTestCase(testCase) }} | ||
{% include 'exception_screenshot.twig' with { testDataEntity: testCase } %} | ||
{% for testStep in testCase.stepsAsSortedSet %} | ||
{% include 'exception_screenshot.twig' with { testDataEntity: testStep } %} | ||
{% endfor %} | ||
{% endif %} | ||
{% endif %} | ||
</td> | ||
</tr> | ||
{% endfor %} | ||
</table> | ||
{% set testDataEntityType = getTestDataEntityType(testDataEntity) %} | ||
{% if ('TestSuite' == testDataEntityType) %} | ||
{% include 'detailed_summary_suite.twig' with { testsuite: testDataEntity} %} | ||
{% elseif ('TestCase' == testDataEntityType) %} | ||
{% include 'detailed_summary_case.twig' with { testCase: testDataEntity } %} | ||
{% elseif ('TestCaseStep' == testDataEntityType) %} | ||
{% include 'detailed_summary_step.twig' with { testStep: testDataEntity } %} | ||
{% endif %} |
Oops, something went wrong.