New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

vision

Package Overview
Dependencies
Maintainers
1
Versions
29
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vision - npm Package Compare versions

Comparing version 1.0.2 to 1.0.3

examples/cms/_pages/.placeholder

2

package.json
{
"name": "vision",
"description": "Templates rendering support for hapi.js",
"version": "1.0.2",
"version": "1.0.3",
"repository": "git://github.com/hapijs/vision",

@@ -6,0 +6,0 @@ "main": "index",

@@ -23,34 +23,4 @@ // Load modules

describe('Vision', function () {
describe('Manager', function () {
it('should not fail if rendered template returns undefined', function (done) {
var server = new Hapi.Server();
server.handler('viewTest', Vision.handler);
server._views = new Vision.Manager({
engines: {
html: {
module: {
compile: function (template, options) {
return function (context, options) {
return undefined;
}
}
},
path: __dirname + '/templates/valid'
}
}
});
server.route({ method: 'GET', path: '/', handler: { viewTest: { template: 'test.html' } } });
server.inject('/', function (res) {
expect(res.statusCode).to.equal(200);
done();
});
});
it('renders handlebars template', function (done) {

@@ -237,4 +207,34 @@

describe('Layout', function (done) {
it('should not fail if rendered template returns undefined', function (done) {
var server = new Hapi.Server();
server.handler('viewTest', Vision.handler);
server._views = new Vision.Manager({
engines: {
html: {
module: {
compile: function (template, options) {
return function (context, options) {
return undefined;
}
}
},
path: __dirname + '/templates/valid'
}
}
});
server.route({ method: 'GET', path: '/', handler: { viewTest: { template: 'test.html' } } });
server.inject('/', function (res) {
expect(res.statusCode).to.equal(200);
done();
});
});
describe('with layout', function (done) {
it('returns response', function (done) {

@@ -448,3 +448,3 @@

describe('Multiple', function () {
describe('with multiple engines', function () {

@@ -451,0 +451,0 @@ it('renders handlebars template', function (done) {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc