Socket
Socket
Sign inDemoInstall

camunda-external-task-client-js

Package Overview
Dependencies
Maintainers
1
Versions
23
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

camunda-external-task-client-js - npm Package Compare versions

Comparing version 2.1.0 to 2.1.1

.github/workflows/CI.yml

10

CHANGELOG.md
# Changelog
## 2.1.1
### Bug Fixes
- Fix loading file variables ([#208](https://github.com/camunda/camunda-external-task-client-js/pull/208))
### Dependency Updates
- Bump lodash to version 4.17.21
- Bump ws to 5.2.3
- Bump normalize-url to 4.5.1
- Bump y18n to 3.2.2
## 2.1.0

@@ -4,0 +14,0 @@ ### Features

10

lib/__internal/EngineService.js

@@ -50,3 +50,11 @@ /*

try {
return await got(url, newOptions).json();
const { body, headers } = await got(url, {
...newOptions,
responseType: "buffer"
});
if (headers["content-type"] === "application/json") {
return JSON.parse(body.toString("utf-8"));
} else {
return body;
}
} catch (e) {

@@ -53,0 +61,0 @@ if (e instanceof got.HTTPError) {

9

lib/__internal/EngineService.test.js

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

const expectedUrl = `${engineService.baseUrl}${path}`;
const expectedPayload = { method, key: "some value" };
const expectedPayload = {
method,
responseType: "buffer",
key: "some value"
};

@@ -212,3 +216,4 @@ //when

...someExpectedAddedPayload,
...anotherExpectedAddedPayload
...anotherExpectedAddedPayload,
responseType: "buffer"
};

@@ -215,0 +220,0 @@

@@ -188,3 +188,3 @@ /*

expect(pollSpy).toHaveBeenCalledTimes(3);
expect(engineService.fetchAndLock).toHaveBeenCalledTimes(2);
expect(engineService.fetchAndLock).toHaveBeenCalledTimes(1);
});

@@ -191,0 +191,0 @@ });

@@ -65,3 +65,3 @@ /*

this.content = this.remotePath
? Buffer.from(await this.engineService.get(this.remotePath), "base64")
? await this.engineService.get(this.remotePath)
: await this.__readFile(this.localPath);

@@ -68,0 +68,0 @@

@@ -62,8 +62,9 @@ /*

const engineService = {
get: jest.fn().mockImplementation(() => Promise.resolve(""))
get: jest
.fn()
.mockImplementation(() => Promise.resolve(Buffer.from("", "utf-8")))
};
const remotePath = "some/remote/path";
const expectedBuffer = Buffer.from(
await engineService.get(this.remotePath),
"base64"
await engineService.get(this.remotePath)
);

@@ -100,4 +101,5 @@ const file = await new File({ remotePath, engineService }).load();

};
const value = "this some random value";
const expectedTypedValue = {
value: Buffer.from("this some random value").toString("base64"),
value: Buffer.from(value).toString("utf-8"),
type: "file",

@@ -107,5 +109,3 @@ valueInfo

const engineService = {
get: jest
.fn()
.mockImplementation(() => Promise.resolve(expectedTypedValue.value))
get: jest.fn().mockImplementation(() => Promise.resolve(value))
};

@@ -112,0 +112,0 @@ const remotePath = "some/remote/path";

{
"version": "2.1.0",
"version": "2.1.1",
"name": "camunda-external-task-client-js",

@@ -10,3 +10,3 @@ "main": "index.js",

"pretest": "node_modules/.bin/eslint lib/ examples/ index.js",
"test": "jest lib --verbose --coverage && node test/license-check.js",
"test": "jest lib --verbose --coverage --no-color && node test/license-check.js",
"test:watch": "jest lib --watch --verbose --coverage"

@@ -13,0 +13,0 @@ },

# camunda-external-task-client
[![npm version](https://badge.fury.io/js/camunda-external-task-client-js.svg)](https://badge.fury.io/js/camunda-external-task-client-js)
[![Build Status](https://travis-ci.org/camunda/camunda-external-task-client-js.svg?branch=master)](https://travis-ci.org/camunda/camunda-external-task-client-js)
![CI](https://github.com/camunda/camunda-external-task-client-js/actions/workflows/CI.yml/badge.svg)

@@ -202,3 +202,3 @@ Implement your [BPMN Service Task](https://docs.camunda.org/manual/latest/user-guide/process-engine/external-tasks/) in

* [Documentation](http://docs.camunda.org/latest/)
* [Documentation](https://docs.camunda.org/manual/latest/)
* [Forum](https://forum.camunda.org)

@@ -205,0 +205,0 @@ * [Stackoverflow](https://stackoverflow.com/questions/tagged/camunda)

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