Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

testdouble

Package Overview
Dependencies
Maintainers
1
Versions
115
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

testdouble - npm Package Compare versions

Comparing version 3.4.0 to 3.5.0

lib/replace/jest-module.js

12

CHANGELOG.md
# Change Log
## [v3.5.0](https://github.com/testdouble/testdouble.js/tree/v3.5.0) (2018-02-11)
[Full Changelog](https://github.com/testdouble/testdouble.js/compare/v3.4.0...v3.5.0)
**Closed issues:**
- Warn jest users when they call td.replace\(moduleName\) and point them to testdouble-jest [\#337](https://github.com/testdouble/testdouble.js/issues/337)
- td.replace doesn't work with Jest [\#331](https://github.com/testdouble/testdouble.js/issues/331)
**Merged pull requests:**
- Jest support for td replace [\#338](https://github.com/testdouble/testdouble.js/pull/338) ([searls](https://github.com/searls))
## [v3.4.0](https://github.com/testdouble/testdouble.js/tree/v3.4.0) (2018-02-10)

@@ -4,0 +16,0 @@ [Full Changelog](https://github.com/testdouble/testdouble.js/compare/v3.3.4...v3.4.0)

@@ -7,3 +7,6 @@ 'use strict';

var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
exports.default = function (path, stub) {
if ((typeof jest === 'undefined' ? 'undefined' : _typeof(jest)) === 'object') return _jestModule2.default.apply(undefined, arguments);
if (arguments.length > 1) {

@@ -30,2 +33,6 @@ return (0, _quibble2.default)(path, stub);

var _jestModule = require('./jest-module');
var _jestModule2 = _interopRequireDefault(_jestModule);
var _imitate = require('../imitate');

@@ -32,0 +39,0 @@

2

lib/version.js

@@ -6,2 +6,2 @@ 'use strict';

});
exports.default = '3.4.0';
exports.default = '3.5.0';
{
"name": "testdouble",
"version": "3.4.0",
"version": "3.5.0",
"description": "A minimal test double library for TDD with JavaScript",

@@ -41,11 +41,7 @@ "homepage": "https://github.com/testdouble/testdouble.js",

"test:typescript": "tsc --outDir generated/typescript -p regression/typescript && node generated/typescript/test.js",
"test:example:webpack": "cd examples/webpack && npm install && npm test",
"test:example:node": "cd examples/node && npm install && npm test",
"test:example:lineman": "cd examples/lineman && npm install && npm test",
"test:example:babel": "cd examples/babel && npm install && npm test",
"test:example": "npm run test:example:node && npm run test:example:lineman && npm run test:example:webpack && npm run test:example:babel",
"test:example": "./script/run-examples",
"version:write": "echo \"export default '$npm_package_version'\" > src/version.js",
"version:changelog": "if command -v github_changelog_generator &>/dev/null; then github_changelog_generator; git commit -m \"Changelog for $npm_package_version\" CHANGELOG.md; else echo Versioning requires you first run 'gem install github_changelog_generator' >&2; fi",
"preversion": "git pull --rebase && npm run test:ci",
"version": "rm -rf node_modules && npm i && npm run version:write && npm run compile && git add src/version.js",
"version": "npm run version:write && npm run compile && git add src/version.js",
"postversion": "git push --tags && npm run version:changelog && git push && npm publish",

@@ -52,0 +48,0 @@ "prepare": "npm run compile"

@@ -44,2 +44,9 @@ # testdouble.js

If you're using testdouble.js in conjunction with another test framework, you
may also want to check out one of these extensions:
* [testdouble-jest](https://github.com/testdouble/testdouble-jest)
* [testdouble-chai](https://github.com/basecase/testdouble-chai)
* [testdouble-jasmine](https://github.com/BrianGenisio/testdouble-jasmine)
## Getting started

@@ -46,0 +53,0 @@

@@ -5,2 +5,3 @@ import _ from '../wrap/lodash'

import jestModule from './jest-module'
import imitate from '../imitate'

@@ -11,2 +12,3 @@

export default function (path, stub) {
if (typeof jest === 'object') return jestModule(...arguments)
if (arguments.length > 1) { return quibble(path, stub) }

@@ -13,0 +15,0 @@ const realThing = requireAt(path)

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

export default '3.4.0'
export default '3.5.0'

Sorry, the diff of this file is too big to display

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