test: Add case for #634
This commit is contained in:
parent
1c60575dc0
commit
f961f0617f
1 changed files with 7 additions and 0 deletions
|
@ -126,3 +126,10 @@ describe 'node feature', ->
|
|||
b = new Buffer(p.innerText)
|
||||
assert.equal b.toString(), '闲云潭影日悠悠,物换星移几度秋'
|
||||
assert.equal Buffer.byteLength(p.innerText), 45
|
||||
|
||||
it 'correctly parses external one-byte UTF8 string', ->
|
||||
p = document.createElement 'p'
|
||||
p.innerText = 'Jøhänñéß'
|
||||
b = new Buffer(p.innerText)
|
||||
assert.equal b.toString(), 'Jøhänñéß'
|
||||
assert.equal Buffer.byteLength(p.innerText), 13
|
||||
|
|
Loading…
Reference in a new issue