adjacent nbsps are now present

pull/3024/head
qintarp 6 years ago
parent 4b9aaabec1
commit 8b66fa23c8

@ -1,15 +1,17 @@
export default { export default {
html: `<div>&nbsp;hello</div> html: `<div>&nbsp;hello</div>
<div>&nbsp;hello&nbsp;</div> <div>&nbsp;hello&nbsp;&nbsp;</div>
<div>&nbsp;hello&nbsp;hello</div>`, <div>&nbsp;hello&nbsp;&nbsp;hello</div>`,
test({ assert, component, target }) { test({ assert, component, target }) {
var divList = target.querySelectorAll('div') var divList = target.querySelectorAll('div')
assert.equal( divList[0].textContent.charCodeAt( 0 ), 160 ); assert.equal( divList[0].textContent.charCodeAt( 0 ), 160 );
assert.equal( divList[1].textContent.charCodeAt( 0 ), 160 ); assert.equal( divList[1].textContent.charCodeAt( 0 ), 160 );
assert.equal( divList[1].textContent.charCodeAt( 6 ), 160 ); assert.equal( divList[1].textContent.charCodeAt( 6 ), 160 );
assert.equal( divList[1].textContent.charCodeAt( 7 ), 160 );
assert.equal( divList[2].textContent.charCodeAt( 0 ), 160 ); assert.equal( divList[2].textContent.charCodeAt( 0 ), 160 );
assert.equal( divList[2].textContent.charCodeAt( 6 ), 160 ); assert.equal( divList[2].textContent.charCodeAt( 6 ), 160 );
assert.equal( divList[2].textContent.charCodeAt( 7 ), 160 );
} }

Loading…
Cancel
Save