tbuchok / vast-xml

A Node module for creating real-time VAST XML responses.
48 stars 27 forks source link

URL Safe #38

Open lavnrose opened 8 years ago

lavnrose commented 8 years ago

Usually URL can contain special character like '&', and it must use urlencode. For easy to use, we can use CDATA.

tbuchok commented 8 years ago

@lavnrose looking at this momentarily -- needed to get full xcode on my machine as libxml i think needed the full version and not just command line. hadn't rebuilt this repo since changing computers a few months ago!

tbuchok commented 8 years ago

@lavnrose this doesn't look to pass the xsd schema validation. did you experience different results:

$ npm t

yields en error:

# validates non-linear vast xml
not ok 74 It validates against the VAST .xsd
  ---
    file:   /Users/tombuchok/vast-xml/test/index.test.js
    line:   39
    column: 5
    stack:  
      - getCaller (/Users/tombuchok/vast-xml/node_modules/tap/lib/tap-assert.js:418:17)
      - Function.assert (/Users/tombuchok/vast-xml/node_modules/tap/lib/tap-assert.js:21:16)
      - Test._testAssert [as ok] (/Users/tombuchok/vast-xml/node_modules/tap/lib/tap-test.js:86:16)
      - Test.<anonymous> (/Users/tombuchok/vast-xml/test/index.test.js:39:5)
      - Test.emit (events.js:129:20)
      - Test.emit (/Users/tombuchok/vast-xml/node_modules/tap/lib/tap-test.js:103:8)
      - GlobalHarness.Harness.process (/Users/tombuchok/vast-xml/node_modules/tap/lib/tap-harness.js:86:13)
      - process._tickCallback (node.js:355:11)
      - Function.Module.runMain (module.js:503:11)
      - startup (node.js:129:16)
  ...

i'd prefer not to merge this until we resolve the error. can you take a look?

lavnrose commented 8 years ago

@tbuchok I am sorry to confuse you. the issue have been fixed now, also I've checked it as below.

# validates non-linear vast xml
ok 74 It validates against the VAST .xsd
# validates wrapper vast XML
ok 75 It validates against the VAST .xsd
# validates wrapper with companion vast XML
ok 76 it ensures that companion ads are present
ok 77 It validates against the VAST .xsd
# omit tracking
ok 78 It should not include impressions
# validates vast with top level error tag and no ads
ok 79 It has Error element
ok 80 It has not Ad element

1..80
# tests 80
# pass  80

# ok