Test Case for zjrJS.Doc.cE() - Stable Test Suite for zjrJS

This information lives on a webpage hosted at the following web address: 'https://www.omegajunior.net/code/zjrjs/stable.php'.

Showing whether zjrJS.Doc.cE() actually works.

Used zjrJS Version:

Stable Minified version 20141202t2322 of zjrJS.


 

Preconditions
Javascript must be allowed to run on this page.

Successful When...
In the form, after each pressing on the Create button, an extra checkbox appears.
Actions
Extra Checkboxes

Test Code:

          var test=({
	amount: 0
	,
	run: function () {"use strict";
		if ( 
			!test.require( "zjrJS.Doc.cE", "function" ) 
			|| !test.require( "zjrJS.Doc.aC", "function" ) 
			|| !test.require( "zjrJS.Doc.cT", "function" ) 
			|| !test.require( "zjrJS.Doc.eid", "function" ) 
		) {
			return false;
		}
		var D = zjrJS.Doc, receiver, label, input;
		receiver = D.eid( "receiver" );
		test.amount += 1;
		label = D.cE( "label" );
		input = D.aC( D.cE( "input" ), label );
		input.type = "checkbox";
		input.checked = (test.amount % 2 === 0);
		D.aC( D.cT( "Created " +  test.amount), label );
		D.aC( D.cE( "br" ), label );
		D.aC( label, receiver );
		D = receiver = label = input = null;
		return false;
	}
});
        

Download:

Download zjrJS’ latest stable build (20141202t2322) minified (7.1KB).

Download zjrJS’ latest stable build (20141202t2322) (11.9KB).

Clicky Analytics