Closed kuba-orlik closed 8 years ago
The changes are documented in user-reference:
https://github.com/sealcode/sealious-user-reference/commit/b251ace2416cf1ae700df9acf4b1f1dd2a0aa194
Problems with tests:
git checkout field_type_html
npm install
- sanitize_html
installsnpm test
, error:$ npm test
> sealious@0.7.11 test C:\Users\anwi\Desktop\sealious
> mocha --recursive tests
module.js:442
throw err;
^
Error: Cannot find module 'sanitize-html'
at Function.Module._resolveFilename (module.js:440:15)
at Function.Module._load (module.js:388:25)
at Module.require (module.js:468:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (C:\Users\anwi\Desktop\sealious\lib\base-chips\field-types\html.js:1:84)
at Module._compile (module.js:541:32)
at Object.Module._extensions..js (module.js:550:10)
at Module.load (module.js:458:32)
at tryModuleLoad (module.js:417:12)
at Function.Module._load (module.js:409:3)
at Module.require (module.js:468:17)
at require (internal/module.js:20:19)
at locreq (C:\Users\anwi\Desktop\sealious\node_modules\locreq\index.js:33:9)
at curried (C:\Users\anwi\Desktop\sealious\node_modules\locreq\index.js:38:10)
at Object.<anonymous> (C:\Users\anwi\Desktop\sealious\tests\unit-tests\base-chips\field-types\html.test.js:4:25)
at Module._compile (module.js:541:32)
at Object.Module._extensions..js (module.js:550:10)
at Module.load (module.js:458:32)
at tryModuleLoad (module.js:417:12)
at Function.Module._load (module.js:409:3)
at Module.require (module.js:468:17)
at require (internal/module.js:20:19)
at C:\Users\anwi\Desktop\sealious\node_modules\mocha\lib\mocha.js:220:27
at Array.forEach (native)
at Mocha.loadFiles (C:\Users\anwi\Desktop\sealious\node_modules\mocha\lib\mocha.js:217:14)
at Mocha.run (C:\Users\anwi\Desktop\sealious\node_modules\mocha\lib\mocha.js:485:10)
at Object.<anonymous> (C:\Users\anwi\Desktop\sealious\node_modules\mocha\bin\_mocha:403:18)
at Module._compile (module.js:541:32)
at Object.Module._extensions..js (module.js:550:10)
at Module.load (module.js:458:32)
at tryModuleLoad (module.js:417:12)
at Function.Module._load (module.js:409:3)
at Module.runMain (module.js:575:10)
at run (node.js:348:7)
at startup (node.js:140:9)
at node.js:463:3
npm ERR! Test failed. See above for more details.
I tried to install sanitize_html
specifically, but the error stays the same.
That's very strange, as Travis does not seem to have this issue... I suspect it's something with your instance. Could you clone the repository to a different directory and try there?
I've added a simple html field-type that uses the sanitize-html module to remove any possible xss vulnerabilities. It supports two formats:
safe
andunsafe/original