Skip to content

Commit

Permalink
Add test for the DocumentFragment constructor.
Browse files Browse the repository at this point in the history
  • Loading branch information
bwrrp committed Jun 21, 2017
1 parent 710d26a commit 54a2d0d
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions test/DocumentFragment.tests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,15 @@ describe('DocumentFragment', () => {
chai.assert.equal(df.nodeType, 11);
chai.assert.equal(df.nodeName, '#document-fragment');
chai.assert.equal(df.nodeValue, null);
chai.assert.equal(df.ownerDocument, document);
});

it('can be created using its constructor', () => {
const df = new slimdom.DocumentFragment();
chai.assert.equal(df.nodeType, 11);
chai.assert.equal(df.nodeName, '#document-fragment');
chai.assert.equal(df.nodeValue, null);
chai.assert.equal(df.ownerDocument, slimdom.document);
});

it('can not change its nodeValue', () => {
Expand Down

0 comments on commit 54a2d0d

Please sign in to comment.