You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 7-8.RSVP
Socket
Socket
Sign inDemoInstall

mockttp

Package Overview
Dependencies
Maintainers
1
Versions
122
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.14.4 to 0.14.5

1

dist/rules/handlers.js

@@ -351,2 +351,3 @@ "use strict";

clientReq.body.rawStream.once('error', () => serverReq.abort());
clientReq.once('abort', () => serverReq.abort());
clientRes.once('close', () => serverReq.abort());

@@ -353,0 +354,0 @@ serverReq.once('error', (e) => {

7

dist/server/mockttp-server.js

@@ -188,8 +188,7 @@ "use strict";

let result = null;
response.once('close', () => {
// Aborted is only defined in new node. We use it where it's explicitly false though.
if (result === null && (request.aborted !== false)) {
request.once('aborted', () => {
if (result === null) {
result = 'aborted';
request.timingEvents.abortedTimestamp = now();
this.announceAbortAsync(request);
result = 'aborted';
}

@@ -196,0 +195,0 @@ });

@@ -7,2 +7,3 @@ /**

import express = require("express");
import { EventEmitter } from 'events';
export declare const DEFAULT_STANDALONE_PORT = 45456;

@@ -38,3 +39,3 @@ export declare enum Method {

}
export interface OngoingRequest extends Request {
export interface OngoingRequest extends Request, EventEmitter {
id: string;

@@ -41,0 +42,0 @@ originalUrl: string;

{
"name": "mockttp",
"version": "0.14.4",
"version": "0.14.5",
"description": "Mock HTTP server for testing HTTP clients and stubbing webservices",

@@ -5,0 +5,0 @@ "main": "dist/main.js",

@@ -481,2 +481,3 @@ /**

clientReq.body.rawStream.once('error', () => serverReq.abort());
clientReq.once('abort', () => serverReq.abort());
clientRes.once('close', () => serverReq.abort());

@@ -483,0 +484,0 @@

@@ -213,8 +213,7 @@ /**

let result: 'responded' | 'aborted' | null = null;
response.once('close', () => {
// Aborted is only defined in new node. We use it where it's explicitly false though.
if (result === null && ((request as any).aborted !== false)) {
request.once('aborted', () => {
if (result === null) {
result = 'aborted';
request.timingEvents.abortedTimestamp = now();
this.announceAbortAsync(request);
result = 'aborted';
}

@@ -221,0 +220,0 @@ });

@@ -7,2 +7,3 @@ /**

import express = require("express");
import { EventEmitter } from 'events';

@@ -51,3 +52,3 @@ export const DEFAULT_STANDALONE_PORT = 45456;

export interface OngoingRequest extends Request {
export interface OngoingRequest extends Request, EventEmitter {
id: string;

@@ -54,0 +55,0 @@ originalUrl: string;

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc