fix(core): update

This commit is contained in:
Philipp Kunz 2021-11-07 15:58:45 +01:00
parent 4b1f058a21
commit 797cac672b
7 changed files with 2508 additions and 1451 deletions

View File

@ -12,6 +12,9 @@ stages:
- release - release
- metadata - metadata
before_script:
- npm install -g @shipzone/npmci
# ==================== # ====================
# security stage # security stage
# ==================== # ====================
@ -36,6 +39,7 @@ auditProductionDependencies:
- npmci command npm audit --audit-level=high --only=prod --production - npmci command npm audit --audit-level=high --only=prod --production
tags: tags:
- docker - docker
allow_failure: true
auditDevDependencies: auditDevDependencies:
image: registry.gitlab.com/hosttoday/ht-docker-node:npmci image: registry.gitlab.com/hosttoday/ht-docker-node:npmci

24
.vscode/launch.json vendored
View File

@ -2,28 +2,10 @@
"version": "0.2.0", "version": "0.2.0",
"configurations": [ "configurations": [
{ {
"name": "current file", "command": "npm test",
"type": "node", "name": "Run npm test",
"request": "launch", "request": "launch",
"args": [ "type": "node-terminal"
"${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"
} }
] ]
} }

3915
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -13,17 +13,17 @@
"format": "(gitzone format)" "format": "(gitzone format)"
}, },
"devDependencies": { "devDependencies": {
"@gitzone/tsbuild": "^2.1.26", "@gitzone/tsbuild": "^2.1.28",
"@gitzone/tstest": "^1.0.54", "@gitzone/tstest": "^1.0.59",
"@pushrocks/tapbundle": "^3.2.14", "@pushrocks/tapbundle": "^3.2.14",
"@types/node": "^16.6.1", "@types/node": "^16.11.6",
"tslint": "^6.1.3", "tslint": "^6.1.3",
"tslint-config-prettier": "^1.15.0" "tslint-config-prettier": "^1.15.0"
}, },
"dependencies": { "dependencies": {
"@pushrocks/smartdelay": "^2.0.13", "@pushrocks/smartdelay": "^2.0.13",
"@pushrocks/smartenv": "^4.0.16", "@pushrocks/smartenv": "^4.0.16",
"puppeteer": "^10.2.0", "puppeteer": "^11.0.0",
"tree-kill": "^1.2.2" "tree-kill": "^1.2.2"
}, },
"files": [ "files": [
@ -41,4 +41,4 @@
"browserslist": [ "browserslist": [
"last 1 chrome versions" "last 1 chrome versions"
] ]
} }

View File

@ -14,6 +14,6 @@ tap.test('should get and stop an Incognito browser', async () => {
await incognitoInstance.start(); await incognitoInstance.start();
const page = await incognitoInstance.browser.newPage(); const page = await incognitoInstance.browser.newPage();
await incognitoInstance.stop(); await incognitoInstance.stop();
}) });
tap.start(); tap.start();

View File

@ -35,7 +35,7 @@ export class IncognitoBrowser {
/** /**
* rotate * rotate
*/ */
public async rotateBrowser () { public async rotateBrowser() {
this.browser.close().catch(); this.browser.close().catch();
this.browser = await getEnvAwareBrowserInstance(); this.browser = await getEnvAwareBrowserInstance();
} }

View File

@ -25,7 +25,7 @@ export const getEnvAwareBrowserInstance = async (
console.log(chromeArgs); console.log(chromeArgs);
headlessBrowser = await plugins.puppeteer.launch({ headlessBrowser = await plugins.puppeteer.launch({
args: chromeArgs, args: chromeArgs,
pipe: true pipe: true,
}); });
return headlessBrowser; return headlessBrowser;