Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
mahara
mahara
Commits
9e6d03ca
Commit
9e6d03ca
authored
May 29, 2018
by
Robert Lyon
Committed by
Gerrit Code Review
May 29, 2018
Browse files
Merge "Bug 1772792: Update behat for php7.2"
parents
81198ed0
584c6aff
Changes
2
Hide whitespace changes
Inline
Side-by-side
external/composer.json
View file @
9e6d03ca
{
"require"
:
{
"php"
:
">=5.3.3"
,
"behat/behat"
:
">=3.1.0"
,
"behat/mink"
:
">=1.7.1"
,
"behat/mink-extension"
:
">=2.2"
,
"behat/mink-goutte-driver"
:
">=1.2.1"
,
"behat/mink-selenium2-driver"
:
">=1.3.1"
,
"emuse/behat-html-formatter"
:
">=0.1"
,
"fabpot/goutte"
:
">=3.1.2"
,
"guzzlehttp/guzzle"
:
">=6.2.1"
,
"phpunit/phpunit"
:
">=3.7.38"
"php"
:
">=5.5.6"
,
"behat/behat"
:
"^3.4.0"
,
"behat/mink"
:
"^1.7"
,
"behat/mink-extension"
:
"^2.3"
,
"behat/mink-goutte-driver"
:
"^1.1"
,
"behat/mink-selenium2-driver"
:
"^1.3"
,
"emuse/behat-html-formatter"
:
"^0.1"
,
"fabpot/goutte"
:
"^3.2"
,
"guzzlehttp/guzzle"
:
"^6.3.0"
,
"phpunit/phpunit"
:
"^4.5"
},
"autoload"
:
{
...
...
htdocs/testing/frameworks/behat/html-formatter/Behat2Renderer.php
View file @
9e6d03ca
...
...
@@ -56,58 +56,65 @@ class Behat2Renderer
public
function
renderAfterExercise
(
$obj
)
{
//--> features results
$strFeatPassed
=
''
;
if
(
count
(
$obj
->
getPassedFeatures
())
>
0
)
{
$featTotal
=
0
;
$sceTotal
=
0
;
$stepsTotal
=
0
;
if
(
null
!==
$obj
->
getPassedFeatures
()
&&
count
(
$obj
->
getPassedFeatures
())
>
0
)
{
$strFeatPassed
=
' <strong class="passed">'
.
count
(
$obj
->
getPassedFeatures
())
.
' success</strong>'
;
$featTotal
+=
count
(
$obj
->
getPassedFeatures
());
}
$strFeatFailed
=
''
;
$sumRes
=
'passed'
;
if
(
count
(
$obj
->
getFailedFeatures
())
>
0
)
{
if
(
null
!==
$obj
->
getFailedFeatures
()
&&
count
(
$obj
->
getFailedFeatures
())
>
0
)
{
$strFeatFailed
=
' <strong class="failed">'
.
count
(
$obj
->
getFailedFeatures
())
.
' fail</strong>'
;
$sumRes
=
'failed'
;
$featTotal
+=
count
(
$obj
->
getFailedFeatures
());
}
//--> scenarios results
$strScePassed
=
''
;
if
(
count
(
$obj
->
getPassedScenarios
())
>
0
)
{
if
(
null
!==
$obj
->
getPassedScenarios
()
&&
count
(
$obj
->
getPassedScenarios
())
>
0
)
{
$strScePassed
=
' <strong class="passed">'
.
count
(
$obj
->
getPassedScenarios
())
.
' success</strong>'
;
$sceTotal
+=
count
(
$obj
->
getPassedScenarios
());
}
$strSceFailed
=
''
;
if
(
count
(
$obj
->
getFailedScenarios
())
>
0
)
{
if
(
null
!==
$obj
->
getFailedScenarios
()
&&
count
(
$obj
->
getFailedScenarios
())
>
0
)
{
$strSceFailed
=
' <strong class="failed">'
.
count
(
$obj
->
getFailedScenarios
())
.
' fail</strong>'
;
$sceTotal
+=
count
(
$obj
->
getFailedScenarios
());
}
//--> steps results
$strStepsPassed
=
''
;
if
(
count
(
$obj
->
getPassedSteps
())
>
0
)
{
if
(
null
!==
$obj
->
getPassedSteps
()
&&
count
(
$obj
->
getPassedSteps
())
>
0
)
{
$strStepsPassed
=
' <strong class="passed">'
.
count
(
$obj
->
getPassedSteps
())
.
' success</strong>'
;
$stepsTotal
+=
count
(
$obj
->
getPassedSteps
());
}
$strStepsPending
=
''
;
if
(
count
(
$obj
->
getPendingSteps
())
>
0
)
{
if
(
null
!==
$obj
->
getPendingSteps
()
&&
count
(
$obj
->
getPendingSteps
())
>
0
)
{
$strStepsPending
=
' <strong class="pending">'
.
count
(
$obj
->
getPendingSteps
())
.
' pending</strong>'
;
$stepsTotal
+=
count
(
$obj
->
getPendingSteps
());
}
$strStepsSkipped
=
''
;
if
(
count
(
$obj
->
getSkippedSteps
())
>
0
)
{
if
(
null
!==
$obj
->
getSkippedSteps
()
&&
count
(
$obj
->
getSkippedSteps
())
>
0
)
{
$strStepsSkipped
=
' <strong class="skipped">'
.
count
(
$obj
->
getSkippedSteps
())
.
' skipped</strong>'
;
$stepsTotal
+=
count
(
$obj
->
getSkippedSteps
());
}
$strStepsFailed
=
''
;
if
(
count
(
$obj
->
getFailedSteps
())
>
0
)
{
if
(
null
!==
$obj
->
getFailedSteps
()
&&
count
(
$obj
->
getFailedSteps
())
>
0
)
{
$strStepsFailed
=
' <strong class="failed">'
.
count
(
$obj
->
getFailedSteps
())
.
' fail</strong>'
;
$stepsTotal
+=
count
(
$obj
->
getFailedSteps
());
}
//totals
$featTotal
=
(
count
(
$obj
->
getFailedFeatures
())
+
count
(
$obj
->
getPassedFeatures
()));
$sceTotal
=
(
count
(
$obj
->
getFailedScenarios
())
+
count
(
$obj
->
getPassedScenarios
()))
;
$stepsTotal
=
(
count
(
$obj
->
getFailedSteps
())
+
count
(
$obj
->
getPassedSteps
())
+
count
(
$obj
->
getSkippedSteps
())
+
count
(
$obj
->
getPendingSteps
()))
;
//list of pending steps to display
$strPendingList
=
''
;
if
(
count
(
$obj
->
getPendingSteps
())
>
0
)
{
if
(
null
!==
$obj
->
getPendingSteps
()
&&
count
(
$obj
->
getPendingSteps
())
>
0
)
{
foreach
(
$obj
->
getPendingSteps
()
as
$pendingStep
)
{
$strPendingList
.
=
'
<li>'
.
$pendingStep
->
getKeyword
()
.
' '
.
$pendingStep
->
getText
()
.
'</li>'
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment