serverless-mocha-plugin
Advanced tools
Comparing version 1.3.2 to 1.3.3
@@ -142,3 +142,3 @@ 'use strict'; | ||
const vars = new myModule.serverless.classes.Variables(myModule.serverless); | ||
vars.populateService(); | ||
vars.populateService(this.options); | ||
myModule.getFunctions(funcName) | ||
@@ -145,0 +145,0 @@ .then(utils.getTestFiles) |
{ | ||
"name": "serverless-mocha-plugin", | ||
"version": "1.3.2", | ||
"version": "1.3.3", | ||
"engines": { | ||
@@ -35,7 +35,6 @@ "node": ">=4.0" | ||
"scripts": { | ||
"test": "mocha", | ||
"test": "mocha -t 10000", | ||
"lint": "eslint ." | ||
}, | ||
"devDependencies": { | ||
"chai": "^3.2.0", | ||
"eslint": "^3.3.1", | ||
@@ -47,6 +46,3 @@ "eslint-config-airbnb": "^10.0.1", | ||
"eslint-plugin-react": "^6.1.1", | ||
"mocha": "^2.2.5", | ||
"proxyquire": "^1.7.10", | ||
"serverless": "^1.1.0", | ||
"sinon": "^1.17.6" | ||
"serverless": "^1.7.0" | ||
}, | ||
@@ -53,0 +49,0 @@ "dependencies": { |
@@ -10,2 +10,4 @@ # Serverless Mocha Plugin | ||
More familiar with Jest? Use [serverless-jest-plugin](https://github.com/sc5/serverless-jest-plugin). | ||
## Introduction | ||
@@ -30,3 +32,3 @@ | ||
plugins: | ||
- serverless-mocha-plugin | ||
- serverless-mocha-plugin | ||
``` | ||
@@ -133,6 +135,3 @@ | ||
Copyright (c) 2016 [SC5](http://sc5.io/), licensed for users and contributors under MIT license. | ||
Copyright (c) 2017 [SC5](http://sc5.io/), licensed for users and contributors under MIT license. | ||
https://github.com/SC5/serverless-mocha-plugin/blob/master/LICENSE | ||
[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/SC5/serverless-mocha-plugin/trend.png)](https://bitdeli.com/free "Bitdeli Badge") |
@@ -7,6 +7,8 @@ 'use strict'; | ||
const utils = require('../utils.js'); | ||
const testUtils = require('./testUtils'); | ||
describe('utils', () => { | ||
before(() => { | ||
const tmp = path.join(__dirname, '../', 'tmp'); | ||
process.env.MOCHA_PLUGIN_TEST_DIR = path.join(__dirname); | ||
const tmp = testUtils.getTmpDirPath(); | ||
fse.mkdirsSync(tmp); | ||
@@ -37,4 +39,6 @@ process.chdir(tmp); | ||
it('gets template from a file', () => { | ||
const expectedTemplate = fse.readFileSync('../templates/test-template.ejs', 'utf-8'); | ||
const template = utils.getTemplateFromFile('../templates/test-template.ejs'); | ||
const templatePath = | ||
path.join(process.env.MOCHA_PLUGIN_TEST_DIR, '../', 'templates/test-template.ejs'); | ||
const expectedTemplate = fse.readFileSync(templatePath, 'utf-8'); | ||
const template = utils.getTemplateFromFile(templatePath); | ||
expect(template).to.be.equal(expectedTemplate); | ||
@@ -41,0 +45,0 @@ }); |
Sorry, the diff of this file is not supported yet
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
Shell access
Supply chain riskThis module accesses the system shell. Accessing the system shell increases the risk of executing arbitrary code.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
39754
7
24
747
135
24
3