Navigation Menu

Skip to content

Commit

Permalink
test that newly created Image and Options have a nodeName
Browse files Browse the repository at this point in the history
  • Loading branch information
client9 committed Apr 23, 2010
1 parent f83c638 commit 4ec2133
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions specs/html/spec.js
Expand Up @@ -584,6 +584,8 @@ test('HTMLTitleElement', function() {
test("Image", function() {
var x = new Image();
equals(x, '[object HTMLImageElement]', 'toString');
equals(x.nodeName, 'IMG', 'constructor sets nodeName');
equals(x.tagName, 'IMG', 'contructor sets tagName');
equals(x.src, '', 'new image has src as empty string');

// determined experimentally
Expand Down Expand Up @@ -620,6 +622,8 @@ test("Image", function() {
test("Option", function() {
var x = new Option();
equals(x.toString(), '[object HTMLOptionElement]', 'toString');
equals(x.nodeName, 'OPTION', 'constructor sets nodeName');
equals(x.tagName, 'OPTION', 'constructor sets tagName');
equals(x.form, null, 'get form is null');
equals(x.selected, false, 'selected is false');

Expand Down

0 comments on commit 4ec2133

Please sign in to comment.