File: encoding.coffee

package info (click to toggle)
node-xml2js 0.6.2%2B~cs15.1.1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,312 kB
  • sloc: xml: 119; javascript: 7; makefile: 2
file content (13 lines) | stat: -rw-r--r-- 340 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
suite 'Tests specific to issues:', ->
  test 'Encoding regex', ->
    eq(
      xml('root', {encoding: 'UTF-8'}).end()
      '<?xml version="1.0" encoding="UTF-8"?><root/>'
    )

    err(
      () -> xml('root', {encoding: 'A------------------------------------!'})
      /Invalid encoding: A------------------------------------!/
    )