diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 9a4467e..a70f7eb 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -12,6 +12,9 @@ stages: - release - metadata +before_script: + - npm install -g @shipzone/npmci + # ==================== # security stage # ==================== @@ -36,6 +39,7 @@ auditProductionDependencies: - npmci command npm audit --audit-level=high --only=prod --production tags: - docker + allow_failure: true auditDevDependencies: image: registry.gitlab.com/hosttoday/ht-docker-node:npmci diff --git a/.vscode/launch.json b/.vscode/launch.json index 112db52..26e9f92 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -2,28 +2,10 @@ "version": "0.2.0", "configurations": [ { - "name": "current file", - "type": "node", + "command": "npm test", + "name": "Run npm test", "request": "launch", - "args": [ - "${relativeFile}" - ], - "runtimeArgs": ["-r", "@gitzone/tsrun"], - "cwd": "${workspaceRoot}", - "protocol": "inspector", - "internalConsoleOptions": "openOnSessionStart" - }, - { - "name": "test.ts", - "type": "node", - "request": "launch", - "args": [ - "test/test.ts" - ], - "runtimeArgs": ["-r", "@gitzone/tsrun"], - "cwd": "${workspaceRoot}", - "protocol": "inspector", - "internalConsoleOptions": "openOnSessionStart" + "type": "node-terminal" } ] } diff --git a/npmextra.json b/npmextra.json index cff850f..027b60c 100644 --- a/npmextra.json +++ b/npmextra.json @@ -9,7 +9,7 @@ "githost": "gitlab.com", "gitscope": "pushrocks", "gitrepo": "webrequest", - "shortDescription": "securely request from browsers", + "description": "securely request from browsers", "npmPackagename": "@pushrocks/webrequest", "license": "MIT" } diff --git a/package.json b/package.json index b78358a..939baee 100644 --- a/package.json +++ b/package.json @@ -43,4 +43,4 @@ "browserslist": [ "last 1 chrome versions" ] -} +} \ No newline at end of file diff --git a/test/test.ts b/test/test.ts index 20ff57f..7f756c9 100644 --- a/test/test.ts +++ b/test/test.ts @@ -55,8 +55,8 @@ tap.test('first test', async (tools) => { console.log('response 1: ' + JSON.stringify(response)); console.log('response 2: ' + JSON.stringify(response2)); - expect(response).toHaveProperty('hithere') //.to.equal('hi'); - expect(response2).toHaveProperty('hithere') //.to.equal('hi'); + expect(response).toHaveProperty('hithere'); //.to.equal('hi'); + expect(response2).toHaveProperty('hithere'); //.to.equal('hi'); }); tap.test('tear down server', async () => { diff --git a/ts/index.ts b/ts/index.ts index 073a6d6..0e701a4 100644 --- a/ts/index.ts +++ b/ts/index.ts @@ -116,7 +116,7 @@ export class WebRequest { method: optionsArg.method, headers: { 'Content-Type': 'application/json', - ...(optionsArg.headers || {}) + ...(optionsArg.headers || {}), }, body: optionsArg.body, });