Skip to content

Commit

Permalink
Include xmlns:xlink in <svg/> definition - update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
matthewnessworthy committed Dec 21, 2018
1 parent 6acd0e0 commit 67177ed
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,9 @@
"sinon": "^1.16.1",
"wd": "^0.4.0"
},
"engines" : { "node" : ">=4.0" },
"engines": {
"node": ">=4.0"
},
"engineStrict": true,
"keywords": [
"gulpplugin",
Expand Down
6 changes: 3 additions & 3 deletions test.js
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ describe('gulp-svgstore unit test', function () {
stream.on('data', function (file) {
var result = file.contents.toString()
var target =
'<svg xmlns="http://www.w3.org/2000/svg">' +
'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">' +
'<symbol id="circle" viewBox="0 0 4 4" preserveAspectRatio="xMinYMid meet"><circle cx="2" cy="2" r="1"/></symbol>' +
'<symbol id="square"><rect x="1" y="1" width="2" height="2"/></symbol>' +
'</svg>'
Expand Down Expand Up @@ -149,7 +149,7 @@ describe('gulp-svgstore unit test', function () {
stream.on('data', function (file) {
var result = file.contents.toString()
var target =
'<svg xmlns="http://www.w3.org/2000/svg">' +
'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">' +
'<symbol id="circle" viewBox="0 0 4 4"><circle cx="2" cy="2" r="1"/></symbol>' +
'</svg>'
assert.equal( result, target )
Expand Down Expand Up @@ -182,7 +182,7 @@ describe('gulp-svgstore unit test', function () {
stream.on('data', function(file){
var result = file.contents.toString()
var target =
'<svg xmlns="http://www.w3.org/2000/svg">' +
'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">' +
'<defs><circle id="circ" cx="2" cy="2" r="1"/></defs>' +
'<symbol id="circle" viewBox="0 0 4 4"/>' +
'</svg>'
Expand Down

0 comments on commit 67177ed

Please sign in to comment.