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

fetchtest

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fetchtest - npm Package Compare versions

Comparing version 1.1.1 to 1.1.2

4

dist/lib.d.ts
/// <reference types="node" />
import { RequestListener, Server } from 'http';
import { RequestOptions, Test, BodyType } from "./Test";
import { RequestOptions, Test, BodyType, RequestResponse } from "./Test";
export default function fetchtest(app: RequestListener | Server, defaultOptions?: RequestOptions): Test;
export { RequestOptions, BodyType };
export { RequestOptions, BodyType, RequestResponse };

@@ -8,2 +8,9 @@ /// <reference types="node" />

export declare type BodyType = Record<string, any>;
export declare type RequestResponse = {
headers: Headers;
status: number;
json: any | null;
redirected: boolean;
url: string;
};
export declare class Test {

@@ -17,37 +24,7 @@ app: Server;

constructor(app: Server, defaultOptions?: RequestOptions);
get(url: string, body?: BodyType, options?: RequestOptions): Promise<{
headers: Headers;
status: number;
json: any;
redirected: boolean;
url: string;
}>;
delete(url: string, body?: BodyType, options?: RequestOptions): Promise<{
headers: Headers;
status: number;
json: any;
redirected: boolean;
url: string;
}>;
post(url: string, body?: BodyType, options?: RequestOptions): Promise<{
headers: Headers;
status: number;
json: any;
redirected: boolean;
url: string;
}>;
put(url: string, body?: BodyType, options?: RequestOptions): Promise<{
headers: Headers;
status: number;
json: any;
redirected: boolean;
url: string;
}>;
patch(url: string, body?: BodyType, options?: RequestOptions): Promise<{
headers: Headers;
status: number;
json: any;
redirected: boolean;
url: string;
}>;
get(url: string, body?: BodyType, options?: RequestOptions): Promise<RequestResponse>;
delete(url: string, body?: BodyType, options?: RequestOptions): Promise<RequestResponse>;
post(url: string, body?: BodyType, options?: RequestOptions): Promise<RequestResponse>;
put(url: string, body?: BodyType, options?: RequestOptions): Promise<RequestResponse>;
patch(url: string, body?: BodyType, options?: RequestOptions): Promise<RequestResponse>;
private _makeRequest;

@@ -54,0 +31,0 @@ private static buildResponse;

{
"name": "fetchtest",
"description": "A fetch wrapper for express testing",
"version": "1.1.1",
"version": "1.1.2",
"license": "MIT",

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

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