Skip to content

Commit c246da1

Browse files
committed
Tests for the stats.
1 parent 3218680 commit c246da1

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

tests/qunit/test-run.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ QUnit.test( 'Render test pass', function( assert ) {
5959
assert.ok( $('.wpe-results-card').length == 2, 'There are 2 results.' );
6060
assert.ok( $('#standardMode').text().includes( 'Your WordPress install is PHP 5.5 compatible.' ), 'Test did pass.' );
6161
assert.ok( '#038103' === helpers.rgb2hex( $( ".wpe-results-card" ).eq( 0 ).css( 'border-left-color' ) ), 'First plugin marked as passed.' );
62+
assert.ok( ! $( '#standardMode' ).text().includes( '0 out of 2' ), 'No scan stats are shown.' );
6263
});
6364

6465
QUnit.test( 'Render test fail', function( assert ) {
@@ -79,6 +80,7 @@ QUnit.test( 'Render test fail', function( assert ) {
7980
assert.ok( ! $('#runButton').hasClass('button-primary-disabled'), "Run button isn't disabled" );
8081
assert.ok( $('.wpe-results-card').length == 7, 'There are 7 results.' );
8182
assert.ok( $('#standardMode').text().includes( 'Your WordPress install is not PHP 5.5 compatible.' ), 'Test did not pass.' );
83+
assert.ok( $( '#standardMode' ).text().includes( '1 out of 7' ), 'Scan stats are correct' );
8284
});
8385

8486
QUnit.test( 'Render test skip', function( assert ) {

0 commit comments

Comments
 (0)