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

@gasket/plugin-jest

Package Overview
Dependencies
Maintainers
8
Versions
143
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@gasket/plugin-jest - npm Package Compare versions

Comparing version 7.2.0-canary.20 to 7.2.0

4

generator/jest.config.js

@@ -1,2 +0,2 @@

const nextJest = require('next/jest');
import nextJest from 'next/jest.js';
const pathToApp = 'pages';

@@ -13,2 +13,2 @@ const createJestConfig = nextJest(pathToApp);

module.exports = createJestConfig(customJestConfig);
export default createJestConfig(customJestConfig);

@@ -0,7 +1,8 @@

import type { Plugin } from '@gasket/core';
export default {
const plugin: Plugin = {
name: '@gasket/plugin-jest',
version: '',
description: '',
hooks: {}
};
export = plugin;
/// <reference types="@gasket/core" />
/// <reference types="create-gasket-app" />
/// <reference types="@gasket/plugin-metadata" />
/// <reference types="@gasket/plugin-express" />

@@ -23,3 +24,4 @@ const {

},
handler: async function create(gasket, { files, pkg }) {
handler: async function create(gasket, context) {
const { files, pkg, typescript, apiApp } = context;
const generatorDir = `${__dirname}/../generator`;

@@ -32,3 +34,3 @@ const isReactProject = pkg.has('dependencies', 'react');

if (isReactProject) {
if (isReactProject && !apiApp) {
files.add(

@@ -44,9 +46,39 @@ `${generatorDir}/*`,

});
pkg.add('scripts', {
'test': 'jest',
'test:watch': 'jest --watchAll',
'test:coverage': 'jest --coverage'
});
} else if (apiApp) {
if (typescript) {
pkg.add('devDependencies', {
'@types/jest': devDependencies['@types/jest'],
'cross-env': devDependencies['cross-env'],
'ts-jest': devDependencies['ts-jest'],
'ts-node': devDependencies['ts-node']
});
pkg.add('scripts', {
'test': "cross-env NODE_OPTIONS='--unhandled-rejections=strict --experimental-vm-modules' jest",
'test:watch': 'npm run test -- --watchAll',
'test:coverage': 'npm run test -- --coverage'
});
} else {
pkg.add('devDependencies', {
'cross-env': devDependencies['cross-env']
});
pkg.add('scripts', {
'test': "cross-env NODE_OPTIONS='--unhandled-rejections=strict --experimental-vm-modules' jest",
'test:watch': 'npm run test -- --watch',
'test:coverage': 'npm run test -- --coverage'
});
}
} else {
pkg.add('scripts', {
'test': 'jest',
'test:watch': 'jest --watchAll',
'test:coverage': 'jest --coverage'
});
}
pkg.add('scripts', {
'test': 'jest',
'test:watch': 'jest --watchAll',
'test:coverage': 'jest --coverage'
});
}

@@ -53,0 +85,0 @@ },

{
"name": "@gasket/plugin-jest",
"version": "7.2.0-canary.20",
"version": "7.2.0",
"description": "Integrated jest into your application.",

@@ -34,6 +34,2 @@ "main": "lib/index.js",

"author": "GoDaddy Operating Company, LLC",
"maintainers": [
"Salil Agrawal <sagrawal@godaddy.com>",
"Andrew Gerard <agerard@godaddy.com>"
],
"license": "MIT",

@@ -51,8 +47,8 @@ "bugs": {

"eslint": "^8.56.0",
"eslint-config-godaddy": "^7.1.0",
"eslint-plugin-jest": "^27.6.3",
"eslint-config-godaddy": "^7.1.1",
"eslint-plugin-jest": "^28.6.0",
"eslint-plugin-json": "^3.1.0",
"eslint-plugin-jsx-a11y": "^6.8.0",
"eslint-plugin-react": "^7.33.2",
"eslint-plugin-unicorn": "^44.0.0",
"eslint-plugin-react": "^7.35.0",
"eslint-plugin-unicorn": "^55.0.0",
"jest": "^29.7.0",

@@ -63,2 +59,4 @@ "jest-environment-jsdom": "^29.7.0",

"react-dom": "^18.2.0",
"ts-jest": "^29.2.5",
"ts-node": "^10.9.2",
"typescript": "^5.4.5"

@@ -80,3 +78,3 @@ },

},
"gitHead": "abdb788c7ff44f4c6db7a5885e96e2dd315273fc"
"gitHead": "8790fd065f4bcb853fc9a2deecf0833999f41443"
}

@@ -8,8 +8,4 @@ # @gasket/plugin-jest

This plugin should only be used during the create command for new apps.
This plugin is only used by presets for `create-gasket-app` and is not installed for apps.
```
gasket create <app-name> --plugins @gasket/plugin-jest
```
## Usage

@@ -35,2 +31,1 @@

[MIT](./LICENSE.md)
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