Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
straker committed Jul 20, 2020
1 parent 5af5247 commit 7ea9884
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
7 changes: 6 additions & 1 deletion test/checks/shared/svg-non-empty-title.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,10 +60,15 @@ describe('svg-non-empty-title tests', function() {
nodeName: 'svg'
});
var child = new axe.SerialVirtualNode({
nodeName: 'title',
nodeName: 'title'
});
var text = new axe.SerialVirtualNode({
nodeName: '#text',
nodeType: 3,
nodeValue: 'Time II: Party'
});
child.parent = serialNode;
child.children = [text];
serialNode.children = [child];

assert.isTrue(checkEvaluate(null, {}, serialNode));
Expand Down
5 changes: 5 additions & 0 deletions test/rule-matches/svg-namespace-matches.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,11 @@ describe('svg-namespace-matches', function() {
var serialNode = new axe.SerialVirtualNode({
nodeName: 'circle'
});
var parent = new axe.SerialVirtualNode({
nodeName: 'svg'
});
parent.children = [serialNode];
serialNode.parent = parent;

assert.isTrue(rule.matches(null, serialNode));
});
Expand Down

0 comments on commit 7ea9884

Please sign in to comment.