tmegos blog

I love school idols / Web developer



wdio configが便利

$ npx wdio config

WDIO Configuration Helper

? Where is your automation backend located? On my local machine
? Which framework do you want to use? mocha
? Do you want to run WebdriverIO commands synchronous or asynchronous? sync
? Where are your test specs located? top.spec.ts
? Do you want WebdriverIO to autogenerate some test files? Yes
? Do you want to use page objects ( No
? Are you using a compiler? TypeScript (
? Which reporter do you want to use? spec
? Do you want to add a service to your test setup? chromedriver
? What is the base url? http://localhost:8080
  • ページオブジェクトパターン使う?って聞いてくるくらいなので、使うのが推奨なのかもしれない
  • ブラウザのドライバをいろいろ選べる


Packages installed successfully, creating configuration file...

Config file installed successfully, creating test files...
To have TypeScript support please add the following packages to your "types" list:
  "compilerOptions": {
    "types": ["node", "@wdio/sync", "@wdio/mocha-framework"]

For for information on TypeScript integration check out:

Configuration file was created successfully!



GitHub Actions ミステイク


Add GitHub Actions · megos/spa-e2e-sandbox@8934fa0 · GitHub

ERROR webdriver: Request failed with status 500 due to unknown error: unknown error: Chrome failed to start: exited abnormally.
  (unknown error: DevToolsActivePort file doesn't exist)
  (The process started from chrome location /usr/bin/google-chrome is no longer running, so ChromeDriver is assuming that Chrome has crashed.)

Add GitHub Actions · megos/spa-e2e-sandbox@215bc95 · GitHub



Add headless option · megos/spa-e2e-sandbox@0d946d5 · GitHub


Add headless option · megos/spa-e2e-sandbox@2c7601f · GitHub


Add no-sandbox option · megos/spa-e2e-sandbox@921328b · GitHub

Starting ChromeDriver 87.0.4280.20 (c99e81631faa0b2a448e658c0dbd8311fb04ddbd-refs/branch-heads/4280@{#355}) on port 9515
Only local connections are allowed.
Please see for suggestions on keeping ChromeDriver safe.
[1610866697.868][SEVERE]: bind() failed: Cannot assign requested address (99)

Fix bind() failed: Cannot assign requested address (99) · megos/spa-e2e-sandbox@781d32f · GitHub

npm installもianwalter/puppeteer@mainを使ってみる


Mod · megos/spa-e2e-sandbox@1360604 · GitHub Mod · megos/spa-e2e-sandbox@c7ac022 · GitHub Mod · megos/spa-e2e-sandbox@197c899 · GitHub

$ snowpack dev
    path_1.default.join(util$j.GLOBAL_CACHE_DIR, crypto_1.default.createHash('md5').update(process.cwd()).digest('hex'));

TypeError: Cannot read property 'GLOBAL_CACHE_DIR' of undefined

GitHub Actionsと格闘して1時間たっても解決しないので心が折れた