[Pkg-javascript-commits] [ltx] 279/469: update #29 test with data from node-xmp/node-xmpp#198

Jonas Smedegaard dr at jones.dk
Wed Aug 31 13:03:12 UTC 2016


This is an automated email from the git hooks/post-receive script.

js pushed a commit to branch master
in repository ltx.

commit 09528e4feb5dad15938bd1fa6b23feeaf805392b
Author: ▟ ▖▟ ▖ <dodo.the.last at gmail.com>
Date:   Sat Nov 30 22:27:58 2013 +0100

    update #29 test with data from node-xmp/node-xmpp#198
---
 test/unicode-test.js | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/test/unicode-test.js b/test/unicode-test.js
index 46b1611..419c4f4 100644
--- a/test/unicode-test.js
+++ b/test/unicode-test.js
@@ -17,6 +17,18 @@ vows.describe('unicode').addBatch({
            )
                .c('body').t('니코드<'.toString('utf8'))
            assert.equal(element.getChildText('body'), text)
+        },
+        'issue-29 test write': function() {
+            var text = '유니코드'
+            var result = '<0message0 0to0="0-1 at chat.fb.com0"0 0type0="0chat0"0>0<0body0>'.split(0)
+            result.push(text)
+            result = result.concat('</0body0>0</0message0>'.split(0))
+            var element = new Element('message', {to:'-1 at chat.fb.com', type:'chat'})
+            element.c('body').t(text.toString('utf8'))
+            element.write(function(c) {
+                assert.equal(result.shift(), c)
+            })
+            assert.equal(result.length, 0)
         }
     }
 }).export(module)

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/ltx.git



More information about the Pkg-javascript-commits mailing list