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

postmark

Package Overview
Dependencies
Maintainers
2
Versions
88
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

postmark - npm Package Compare versions

Comparing version 2.7.0 to 2.7.1

5

dist/client/BaseClient.js

@@ -30,3 +30,3 @@ "use strict";

BaseClient.prototype.setClientOptions = function (configOptions) {
this.clientOptions = configOptions;
this.clientOptions = __assign({}, BaseClient.DefaultOptions, configOptions);
this.buildDefaultHttpClient();

@@ -147,2 +147,3 @@ };

maxContentLength: Infinity,
maxBodyLength: Infinity,
validateStatus: function (status) {

@@ -180,3 +181,3 @@ return status >= 200 && status < 300;

requestHost: "api.postmarkapp.com",
timeout: 60,
timeout: 180,
};

@@ -183,0 +184,0 @@ return BaseClient;

8

dist/client/models/client/ClientOptions.d.ts
export declare namespace ClientOptions {
class Configuration {
useHttps: boolean;
requestHost: string;
timeout: number;
constructor(useHttps: boolean, requestHost: string, timeout: number);
useHttps?: boolean;
requestHost?: string;
timeout?: number;
constructor(useHttps?: boolean, requestHost?: string, timeout?: number);
}

@@ -8,0 +8,0 @@ enum HttpMethod {

@@ -12,3 +12,3 @@ {

],
"version": "2.7.0",
"version": "2.7.1",
"author": "Igor Balos",

@@ -15,0 +15,0 @@ "contributors": [

@@ -27,3 +27,3 @@ import * as postmark from "../../src/index";

requestHost: "api.postmarkapp.com",
timeout: 60,
timeout: 180,
});

@@ -57,2 +57,24 @@ });

it("set clientOptions timeout", () => {
const timeoutValue: number = 10;
client.setClientOptions({timeout: timeoutValue});
expect(client.getClientOptions()).to.eql({
useHttps: true,
requestHost: "api.postmarkapp.com",
timeout: timeoutValue,
});
});
it("set clientOptions https", () => {
const https: boolean = false;
client.setClientOptions({useHttps: https});
expect(client.getClientOptions()).to.eql({
useHttps: https,
requestHost: "api.postmarkapp.com",
timeout: 180,
});
});
describe("errors", () => {

@@ -59,0 +81,0 @@ it("empty token", () => {

@@ -23,3 +23,3 @@ import * as postmark from "../../src/index";

it("default clientOptions", () => {
const defaultClientOptions = { useHttps: true, requestHost: "api.postmarkapp.com", timeout: 60 };
const defaultClientOptions = { useHttps: true, requestHost: "api.postmarkapp.com", timeout: 180 };
expect(client.getClientOptions()).to.eql(defaultClientOptions);

@@ -61,2 +61,23 @@ });

it("set clientOptions timeout", () => {
const timeoutValue: number = 10;
client.setClientOptions({timeout: timeoutValue});
expect(client.getClientOptions()).to.eql({
useHttps: true,
requestHost: "api.postmarkapp.com",
timeout: timeoutValue,
});
});
it("set clientOptions https", () => {
client.setClientOptions({useHttps: false});
expect(client.getClientOptions()).to.eql({
useHttps: false,
requestHost: "api.postmarkapp.com",
timeout: 180,
});
});
it("new clientOptions as object", () => {

@@ -63,0 +84,0 @@ const requestHost = "test";

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

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc