rubycrawl 0.1.2 → 0.1.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (577) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +427 -210
  3. data/lib/rubycrawl/helpers.rb +15 -11
  4. data/lib/rubycrawl/markdown_converter.rb +3 -3
  5. data/lib/rubycrawl/result.rb +10 -11
  6. data/lib/rubycrawl/service_client.rb +25 -3
  7. data/lib/rubycrawl/site_crawler.rb +14 -6
  8. data/lib/rubycrawl/version.rb +1 -1
  9. data/lib/rubycrawl.rb +33 -7
  10. data/node/src/index.js +193 -19
  11. data/rubycrawl.gemspec +3 -2
  12. metadata +2 -567
  13. data/Gemfile +0 -11
  14. data/bin/console +0 -9
  15. data/bin/setup +0 -4
  16. data/node/node_modules/.bin/playwright +0 -1
  17. data/node/node_modules/.bin/playwright-core +0 -1
  18. data/node/node_modules/.package-lock.json +0 -65
  19. data/node/node_modules/dotenv/CHANGELOG.md +0 -520
  20. data/node/node_modules/dotenv/LICENSE +0 -23
  21. data/node/node_modules/dotenv/README-es.md +0 -411
  22. data/node/node_modules/dotenv/README.md +0 -645
  23. data/node/node_modules/dotenv/SECURITY.md +0 -1
  24. data/node/node_modules/dotenv/config.d.ts +0 -1
  25. data/node/node_modules/dotenv/config.js +0 -9
  26. data/node/node_modules/dotenv/lib/cli-options.js +0 -17
  27. data/node/node_modules/dotenv/lib/env-options.js +0 -28
  28. data/node/node_modules/dotenv/lib/main.d.ts +0 -162
  29. data/node/node_modules/dotenv/lib/main.js +0 -386
  30. data/node/node_modules/dotenv/package.json +0 -62
  31. data/node/node_modules/playwright/LICENSE +0 -202
  32. data/node/node_modules/playwright/NOTICE +0 -5
  33. data/node/node_modules/playwright/README.md +0 -168
  34. data/node/node_modules/playwright/ThirdPartyNotices.txt +0 -5042
  35. data/node/node_modules/playwright/cli.js +0 -19
  36. data/node/node_modules/playwright/index.d.ts +0 -17
  37. data/node/node_modules/playwright/index.js +0 -17
  38. data/node/node_modules/playwright/index.mjs +0 -18
  39. data/node/node_modules/playwright/jsx-runtime.js +0 -42
  40. data/node/node_modules/playwright/jsx-runtime.mjs +0 -21
  41. data/node/node_modules/playwright/lib/agents/agentParser.js +0 -89
  42. data/node/node_modules/playwright/lib/agents/copilot-setup-steps.yml +0 -34
  43. data/node/node_modules/playwright/lib/agents/generateAgents.js +0 -348
  44. data/node/node_modules/playwright/lib/agents/playwright-test-coverage.prompt.md +0 -31
  45. data/node/node_modules/playwright/lib/agents/playwright-test-generate.prompt.md +0 -8
  46. data/node/node_modules/playwright/lib/agents/playwright-test-generator.agent.md +0 -88
  47. data/node/node_modules/playwright/lib/agents/playwright-test-heal.prompt.md +0 -6
  48. data/node/node_modules/playwright/lib/agents/playwright-test-healer.agent.md +0 -55
  49. data/node/node_modules/playwright/lib/agents/playwright-test-plan.prompt.md +0 -9
  50. data/node/node_modules/playwright/lib/agents/playwright-test-planner.agent.md +0 -73
  51. data/node/node_modules/playwright/lib/common/config.js +0 -282
  52. data/node/node_modules/playwright/lib/common/configLoader.js +0 -344
  53. data/node/node_modules/playwright/lib/common/esmLoaderHost.js +0 -104
  54. data/node/node_modules/playwright/lib/common/expectBundle.js +0 -28
  55. data/node/node_modules/playwright/lib/common/expectBundleImpl.js +0 -407
  56. data/node/node_modules/playwright/lib/common/fixtures.js +0 -302
  57. data/node/node_modules/playwright/lib/common/globals.js +0 -58
  58. data/node/node_modules/playwright/lib/common/ipc.js +0 -60
  59. data/node/node_modules/playwright/lib/common/poolBuilder.js +0 -85
  60. data/node/node_modules/playwright/lib/common/process.js +0 -132
  61. data/node/node_modules/playwright/lib/common/suiteUtils.js +0 -140
  62. data/node/node_modules/playwright/lib/common/test.js +0 -321
  63. data/node/node_modules/playwright/lib/common/testLoader.js +0 -101
  64. data/node/node_modules/playwright/lib/common/testType.js +0 -298
  65. data/node/node_modules/playwright/lib/common/validators.js +0 -68
  66. data/node/node_modules/playwright/lib/fsWatcher.js +0 -67
  67. data/node/node_modules/playwright/lib/index.js +0 -726
  68. data/node/node_modules/playwright/lib/internalsForTest.js +0 -42
  69. data/node/node_modules/playwright/lib/isomorphic/events.js +0 -77
  70. data/node/node_modules/playwright/lib/isomorphic/folders.js +0 -30
  71. data/node/node_modules/playwright/lib/isomorphic/stringInternPool.js +0 -69
  72. data/node/node_modules/playwright/lib/isomorphic/teleReceiver.js +0 -521
  73. data/node/node_modules/playwright/lib/isomorphic/teleSuiteUpdater.js +0 -157
  74. data/node/node_modules/playwright/lib/isomorphic/testServerConnection.js +0 -225
  75. data/node/node_modules/playwright/lib/isomorphic/testServerInterface.js +0 -16
  76. data/node/node_modules/playwright/lib/isomorphic/testTree.js +0 -329
  77. data/node/node_modules/playwright/lib/isomorphic/types.d.js +0 -16
  78. data/node/node_modules/playwright/lib/loader/loaderMain.js +0 -59
  79. data/node/node_modules/playwright/lib/matchers/expect.js +0 -311
  80. data/node/node_modules/playwright/lib/matchers/matcherHint.js +0 -44
  81. data/node/node_modules/playwright/lib/matchers/matchers.js +0 -383
  82. data/node/node_modules/playwright/lib/matchers/toBeTruthy.js +0 -75
  83. data/node/node_modules/playwright/lib/matchers/toEqual.js +0 -100
  84. data/node/node_modules/playwright/lib/matchers/toHaveURL.js +0 -101
  85. data/node/node_modules/playwright/lib/matchers/toMatchAriaSnapshot.js +0 -159
  86. data/node/node_modules/playwright/lib/matchers/toMatchSnapshot.js +0 -342
  87. data/node/node_modules/playwright/lib/matchers/toMatchText.js +0 -99
  88. data/node/node_modules/playwright/lib/mcp/browser/browserContextFactory.js +0 -329
  89. data/node/node_modules/playwright/lib/mcp/browser/browserServerBackend.js +0 -84
  90. data/node/node_modules/playwright/lib/mcp/browser/config.js +0 -421
  91. data/node/node_modules/playwright/lib/mcp/browser/context.js +0 -244
  92. data/node/node_modules/playwright/lib/mcp/browser/response.js +0 -278
  93. data/node/node_modules/playwright/lib/mcp/browser/sessionLog.js +0 -75
  94. data/node/node_modules/playwright/lib/mcp/browser/tab.js +0 -343
  95. data/node/node_modules/playwright/lib/mcp/browser/tools/common.js +0 -65
  96. data/node/node_modules/playwright/lib/mcp/browser/tools/console.js +0 -46
  97. data/node/node_modules/playwright/lib/mcp/browser/tools/dialogs.js +0 -60
  98. data/node/node_modules/playwright/lib/mcp/browser/tools/evaluate.js +0 -61
  99. data/node/node_modules/playwright/lib/mcp/browser/tools/files.js +0 -58
  100. data/node/node_modules/playwright/lib/mcp/browser/tools/form.js +0 -63
  101. data/node/node_modules/playwright/lib/mcp/browser/tools/install.js +0 -72
  102. data/node/node_modules/playwright/lib/mcp/browser/tools/keyboard.js +0 -107
  103. data/node/node_modules/playwright/lib/mcp/browser/tools/mouse.js +0 -107
  104. data/node/node_modules/playwright/lib/mcp/browser/tools/navigate.js +0 -71
  105. data/node/node_modules/playwright/lib/mcp/browser/tools/network.js +0 -63
  106. data/node/node_modules/playwright/lib/mcp/browser/tools/open.js +0 -57
  107. data/node/node_modules/playwright/lib/mcp/browser/tools/pdf.js +0 -49
  108. data/node/node_modules/playwright/lib/mcp/browser/tools/runCode.js +0 -78
  109. data/node/node_modules/playwright/lib/mcp/browser/tools/screenshot.js +0 -93
  110. data/node/node_modules/playwright/lib/mcp/browser/tools/snapshot.js +0 -173
  111. data/node/node_modules/playwright/lib/mcp/browser/tools/tabs.js +0 -67
  112. data/node/node_modules/playwright/lib/mcp/browser/tools/tool.js +0 -47
  113. data/node/node_modules/playwright/lib/mcp/browser/tools/tracing.js +0 -74
  114. data/node/node_modules/playwright/lib/mcp/browser/tools/utils.js +0 -94
  115. data/node/node_modules/playwright/lib/mcp/browser/tools/verify.js +0 -143
  116. data/node/node_modules/playwright/lib/mcp/browser/tools/wait.js +0 -63
  117. data/node/node_modules/playwright/lib/mcp/browser/tools.js +0 -84
  118. data/node/node_modules/playwright/lib/mcp/browser/watchdog.js +0 -44
  119. data/node/node_modules/playwright/lib/mcp/config.d.js +0 -16
  120. data/node/node_modules/playwright/lib/mcp/extension/cdpRelay.js +0 -351
  121. data/node/node_modules/playwright/lib/mcp/extension/extensionContextFactory.js +0 -76
  122. data/node/node_modules/playwright/lib/mcp/extension/protocol.js +0 -28
  123. data/node/node_modules/playwright/lib/mcp/index.js +0 -61
  124. data/node/node_modules/playwright/lib/mcp/log.js +0 -35
  125. data/node/node_modules/playwright/lib/mcp/program.js +0 -111
  126. data/node/node_modules/playwright/lib/mcp/sdk/exports.js +0 -28
  127. data/node/node_modules/playwright/lib/mcp/sdk/http.js +0 -152
  128. data/node/node_modules/playwright/lib/mcp/sdk/inProcessTransport.js +0 -71
  129. data/node/node_modules/playwright/lib/mcp/sdk/server.js +0 -223
  130. data/node/node_modules/playwright/lib/mcp/sdk/tool.js +0 -47
  131. data/node/node_modules/playwright/lib/mcp/terminal/cli.js +0 -296
  132. data/node/node_modules/playwright/lib/mcp/terminal/command.js +0 -56
  133. data/node/node_modules/playwright/lib/mcp/terminal/commands.js +0 -333
  134. data/node/node_modules/playwright/lib/mcp/terminal/daemon.js +0 -129
  135. data/node/node_modules/playwright/lib/mcp/terminal/help.json +0 -32
  136. data/node/node_modules/playwright/lib/mcp/terminal/helpGenerator.js +0 -88
  137. data/node/node_modules/playwright/lib/mcp/terminal/socketConnection.js +0 -80
  138. data/node/node_modules/playwright/lib/mcp/test/browserBackend.js +0 -98
  139. data/node/node_modules/playwright/lib/mcp/test/generatorTools.js +0 -122
  140. data/node/node_modules/playwright/lib/mcp/test/plannerTools.js +0 -145
  141. data/node/node_modules/playwright/lib/mcp/test/seed.js +0 -82
  142. data/node/node_modules/playwright/lib/mcp/test/streams.js +0 -44
  143. data/node/node_modules/playwright/lib/mcp/test/testBackend.js +0 -99
  144. data/node/node_modules/playwright/lib/mcp/test/testContext.js +0 -285
  145. data/node/node_modules/playwright/lib/mcp/test/testTool.js +0 -30
  146. data/node/node_modules/playwright/lib/mcp/test/testTools.js +0 -108
  147. data/node/node_modules/playwright/lib/plugins/gitCommitInfoPlugin.js +0 -198
  148. data/node/node_modules/playwright/lib/plugins/index.js +0 -28
  149. data/node/node_modules/playwright/lib/plugins/webServerPlugin.js +0 -237
  150. data/node/node_modules/playwright/lib/program.js +0 -417
  151. data/node/node_modules/playwright/lib/reporters/base.js +0 -634
  152. data/node/node_modules/playwright/lib/reporters/blob.js +0 -138
  153. data/node/node_modules/playwright/lib/reporters/dot.js +0 -99
  154. data/node/node_modules/playwright/lib/reporters/empty.js +0 -32
  155. data/node/node_modules/playwright/lib/reporters/github.js +0 -128
  156. data/node/node_modules/playwright/lib/reporters/html.js +0 -633
  157. data/node/node_modules/playwright/lib/reporters/internalReporter.js +0 -138
  158. data/node/node_modules/playwright/lib/reporters/json.js +0 -254
  159. data/node/node_modules/playwright/lib/reporters/junit.js +0 -232
  160. data/node/node_modules/playwright/lib/reporters/line.js +0 -131
  161. data/node/node_modules/playwright/lib/reporters/list.js +0 -253
  162. data/node/node_modules/playwright/lib/reporters/listModeReporter.js +0 -69
  163. data/node/node_modules/playwright/lib/reporters/markdown.js +0 -144
  164. data/node/node_modules/playwright/lib/reporters/merge.js +0 -558
  165. data/node/node_modules/playwright/lib/reporters/multiplexer.js +0 -112
  166. data/node/node_modules/playwright/lib/reporters/reporterV2.js +0 -102
  167. data/node/node_modules/playwright/lib/reporters/teleEmitter.js +0 -317
  168. data/node/node_modules/playwright/lib/reporters/versions/blobV1.js +0 -16
  169. data/node/node_modules/playwright/lib/runner/dispatcher.js +0 -530
  170. data/node/node_modules/playwright/lib/runner/failureTracker.js +0 -72
  171. data/node/node_modules/playwright/lib/runner/lastRun.js +0 -77
  172. data/node/node_modules/playwright/lib/runner/loadUtils.js +0 -334
  173. data/node/node_modules/playwright/lib/runner/loaderHost.js +0 -89
  174. data/node/node_modules/playwright/lib/runner/processHost.js +0 -180
  175. data/node/node_modules/playwright/lib/runner/projectUtils.js +0 -241
  176. data/node/node_modules/playwright/lib/runner/rebase.js +0 -189
  177. data/node/node_modules/playwright/lib/runner/reporters.js +0 -138
  178. data/node/node_modules/playwright/lib/runner/sigIntWatcher.js +0 -96
  179. data/node/node_modules/playwright/lib/runner/storage.js +0 -91
  180. data/node/node_modules/playwright/lib/runner/taskRunner.js +0 -127
  181. data/node/node_modules/playwright/lib/runner/tasks.js +0 -410
  182. data/node/node_modules/playwright/lib/runner/testGroups.js +0 -125
  183. data/node/node_modules/playwright/lib/runner/testRunner.js +0 -398
  184. data/node/node_modules/playwright/lib/runner/testServer.js +0 -269
  185. data/node/node_modules/playwright/lib/runner/uiModeReporter.js +0 -30
  186. data/node/node_modules/playwright/lib/runner/vcs.js +0 -72
  187. data/node/node_modules/playwright/lib/runner/watchMode.js +0 -396
  188. data/node/node_modules/playwright/lib/runner/workerHost.js +0 -104
  189. data/node/node_modules/playwright/lib/third_party/pirates.js +0 -62
  190. data/node/node_modules/playwright/lib/third_party/tsconfig-loader.js +0 -103
  191. data/node/node_modules/playwright/lib/transform/babelBundle.js +0 -46
  192. data/node/node_modules/playwright/lib/transform/babelBundleImpl.js +0 -461
  193. data/node/node_modules/playwright/lib/transform/compilationCache.js +0 -274
  194. data/node/node_modules/playwright/lib/transform/esmLoader.js +0 -103
  195. data/node/node_modules/playwright/lib/transform/md.js +0 -221
  196. data/node/node_modules/playwright/lib/transform/portTransport.js +0 -67
  197. data/node/node_modules/playwright/lib/transform/transform.js +0 -303
  198. data/node/node_modules/playwright/lib/util.js +0 -400
  199. data/node/node_modules/playwright/lib/utilsBundle.js +0 -50
  200. data/node/node_modules/playwright/lib/utilsBundleImpl.js +0 -103
  201. data/node/node_modules/playwright/lib/worker/fixtureRunner.js +0 -262
  202. data/node/node_modules/playwright/lib/worker/testInfo.js +0 -536
  203. data/node/node_modules/playwright/lib/worker/testTracing.js +0 -345
  204. data/node/node_modules/playwright/lib/worker/timeoutManager.js +0 -174
  205. data/node/node_modules/playwright/lib/worker/util.js +0 -31
  206. data/node/node_modules/playwright/lib/worker/workerMain.js +0 -530
  207. data/node/node_modules/playwright/package.json +0 -72
  208. data/node/node_modules/playwright/test.d.ts +0 -18
  209. data/node/node_modules/playwright/test.js +0 -24
  210. data/node/node_modules/playwright/test.mjs +0 -34
  211. data/node/node_modules/playwright/types/test.d.ts +0 -10251
  212. data/node/node_modules/playwright/types/testReporter.d.ts +0 -822
  213. data/node/node_modules/playwright-core/LICENSE +0 -202
  214. data/node/node_modules/playwright-core/NOTICE +0 -5
  215. data/node/node_modules/playwright-core/README.md +0 -3
  216. data/node/node_modules/playwright-core/ThirdPartyNotices.txt +0 -4076
  217. data/node/node_modules/playwright-core/bin/install_media_pack.ps1 +0 -5
  218. data/node/node_modules/playwright-core/bin/install_webkit_wsl.ps1 +0 -33
  219. data/node/node_modules/playwright-core/bin/reinstall_chrome_beta_linux.sh +0 -42
  220. data/node/node_modules/playwright-core/bin/reinstall_chrome_beta_mac.sh +0 -13
  221. data/node/node_modules/playwright-core/bin/reinstall_chrome_beta_win.ps1 +0 -24
  222. data/node/node_modules/playwright-core/bin/reinstall_chrome_stable_linux.sh +0 -42
  223. data/node/node_modules/playwright-core/bin/reinstall_chrome_stable_mac.sh +0 -12
  224. data/node/node_modules/playwright-core/bin/reinstall_chrome_stable_win.ps1 +0 -24
  225. data/node/node_modules/playwright-core/bin/reinstall_msedge_beta_linux.sh +0 -48
  226. data/node/node_modules/playwright-core/bin/reinstall_msedge_beta_mac.sh +0 -11
  227. data/node/node_modules/playwright-core/bin/reinstall_msedge_beta_win.ps1 +0 -23
  228. data/node/node_modules/playwright-core/bin/reinstall_msedge_dev_linux.sh +0 -48
  229. data/node/node_modules/playwright-core/bin/reinstall_msedge_dev_mac.sh +0 -11
  230. data/node/node_modules/playwright-core/bin/reinstall_msedge_dev_win.ps1 +0 -23
  231. data/node/node_modules/playwright-core/bin/reinstall_msedge_stable_linux.sh +0 -48
  232. data/node/node_modules/playwright-core/bin/reinstall_msedge_stable_mac.sh +0 -11
  233. data/node/node_modules/playwright-core/bin/reinstall_msedge_stable_win.ps1 +0 -24
  234. data/node/node_modules/playwright-core/browsers.json +0 -79
  235. data/node/node_modules/playwright-core/cli.js +0 -18
  236. data/node/node_modules/playwright-core/index.d.ts +0 -17
  237. data/node/node_modules/playwright-core/index.js +0 -32
  238. data/node/node_modules/playwright-core/index.mjs +0 -28
  239. data/node/node_modules/playwright-core/lib/androidServerImpl.js +0 -65
  240. data/node/node_modules/playwright-core/lib/browserServerImpl.js +0 -120
  241. data/node/node_modules/playwright-core/lib/cli/driver.js +0 -97
  242. data/node/node_modules/playwright-core/lib/cli/program.js +0 -589
  243. data/node/node_modules/playwright-core/lib/cli/programWithTestStub.js +0 -74
  244. data/node/node_modules/playwright-core/lib/client/android.js +0 -361
  245. data/node/node_modules/playwright-core/lib/client/api.js +0 -137
  246. data/node/node_modules/playwright-core/lib/client/artifact.js +0 -79
  247. data/node/node_modules/playwright-core/lib/client/browser.js +0 -161
  248. data/node/node_modules/playwright-core/lib/client/browserContext.js +0 -582
  249. data/node/node_modules/playwright-core/lib/client/browserType.js +0 -185
  250. data/node/node_modules/playwright-core/lib/client/cdpSession.js +0 -51
  251. data/node/node_modules/playwright-core/lib/client/channelOwner.js +0 -194
  252. data/node/node_modules/playwright-core/lib/client/clientHelper.js +0 -64
  253. data/node/node_modules/playwright-core/lib/client/clientInstrumentation.js +0 -55
  254. data/node/node_modules/playwright-core/lib/client/clientStackTrace.js +0 -69
  255. data/node/node_modules/playwright-core/lib/client/clock.js +0 -68
  256. data/node/node_modules/playwright-core/lib/client/connection.js +0 -318
  257. data/node/node_modules/playwright-core/lib/client/consoleMessage.js +0 -58
  258. data/node/node_modules/playwright-core/lib/client/coverage.js +0 -44
  259. data/node/node_modules/playwright-core/lib/client/dialog.js +0 -56
  260. data/node/node_modules/playwright-core/lib/client/download.js +0 -62
  261. data/node/node_modules/playwright-core/lib/client/electron.js +0 -138
  262. data/node/node_modules/playwright-core/lib/client/elementHandle.js +0 -284
  263. data/node/node_modules/playwright-core/lib/client/errors.js +0 -77
  264. data/node/node_modules/playwright-core/lib/client/eventEmitter.js +0 -314
  265. data/node/node_modules/playwright-core/lib/client/events.js +0 -103
  266. data/node/node_modules/playwright-core/lib/client/fetch.js +0 -368
  267. data/node/node_modules/playwright-core/lib/client/fileChooser.js +0 -46
  268. data/node/node_modules/playwright-core/lib/client/fileUtils.js +0 -34
  269. data/node/node_modules/playwright-core/lib/client/frame.js +0 -409
  270. data/node/node_modules/playwright-core/lib/client/harRouter.js +0 -87
  271. data/node/node_modules/playwright-core/lib/client/input.js +0 -84
  272. data/node/node_modules/playwright-core/lib/client/jsHandle.js +0 -109
  273. data/node/node_modules/playwright-core/lib/client/jsonPipe.js +0 -39
  274. data/node/node_modules/playwright-core/lib/client/localUtils.js +0 -60
  275. data/node/node_modules/playwright-core/lib/client/locator.js +0 -369
  276. data/node/node_modules/playwright-core/lib/client/network.js +0 -747
  277. data/node/node_modules/playwright-core/lib/client/page.js +0 -745
  278. data/node/node_modules/playwright-core/lib/client/pageAgent.js +0 -64
  279. data/node/node_modules/playwright-core/lib/client/platform.js +0 -77
  280. data/node/node_modules/playwright-core/lib/client/playwright.js +0 -71
  281. data/node/node_modules/playwright-core/lib/client/selectors.js +0 -55
  282. data/node/node_modules/playwright-core/lib/client/stream.js +0 -39
  283. data/node/node_modules/playwright-core/lib/client/timeoutSettings.js +0 -79
  284. data/node/node_modules/playwright-core/lib/client/tracing.js +0 -119
  285. data/node/node_modules/playwright-core/lib/client/types.js +0 -28
  286. data/node/node_modules/playwright-core/lib/client/video.js +0 -59
  287. data/node/node_modules/playwright-core/lib/client/waiter.js +0 -142
  288. data/node/node_modules/playwright-core/lib/client/webError.js +0 -39
  289. data/node/node_modules/playwright-core/lib/client/webSocket.js +0 -93
  290. data/node/node_modules/playwright-core/lib/client/worker.js +0 -85
  291. data/node/node_modules/playwright-core/lib/client/writableStream.js +0 -39
  292. data/node/node_modules/playwright-core/lib/generated/bindingsControllerSource.js +0 -28
  293. data/node/node_modules/playwright-core/lib/generated/clockSource.js +0 -28
  294. data/node/node_modules/playwright-core/lib/generated/injectedScriptSource.js +0 -28
  295. data/node/node_modules/playwright-core/lib/generated/pollingRecorderSource.js +0 -28
  296. data/node/node_modules/playwright-core/lib/generated/storageScriptSource.js +0 -28
  297. data/node/node_modules/playwright-core/lib/generated/utilityScriptSource.js +0 -28
  298. data/node/node_modules/playwright-core/lib/generated/webSocketMockSource.js +0 -336
  299. data/node/node_modules/playwright-core/lib/inProcessFactory.js +0 -60
  300. data/node/node_modules/playwright-core/lib/inprocess.js +0 -3
  301. data/node/node_modules/playwright-core/lib/mcpBundle.js +0 -84
  302. data/node/node_modules/playwright-core/lib/mcpBundleImpl/index.js +0 -147
  303. data/node/node_modules/playwright-core/lib/outofprocess.js +0 -76
  304. data/node/node_modules/playwright-core/lib/protocol/serializers.js +0 -197
  305. data/node/node_modules/playwright-core/lib/protocol/validator.js +0 -2969
  306. data/node/node_modules/playwright-core/lib/protocol/validatorPrimitives.js +0 -193
  307. data/node/node_modules/playwright-core/lib/remote/playwrightConnection.js +0 -129
  308. data/node/node_modules/playwright-core/lib/remote/playwrightServer.js +0 -334
  309. data/node/node_modules/playwright-core/lib/server/agent/actionRunner.js +0 -335
  310. data/node/node_modules/playwright-core/lib/server/agent/actions.js +0 -128
  311. data/node/node_modules/playwright-core/lib/server/agent/codegen.js +0 -111
  312. data/node/node_modules/playwright-core/lib/server/agent/context.js +0 -150
  313. data/node/node_modules/playwright-core/lib/server/agent/expectTools.js +0 -156
  314. data/node/node_modules/playwright-core/lib/server/agent/pageAgent.js +0 -204
  315. data/node/node_modules/playwright-core/lib/server/agent/performTools.js +0 -262
  316. data/node/node_modules/playwright-core/lib/server/agent/tool.js +0 -109
  317. data/node/node_modules/playwright-core/lib/server/android/android.js +0 -465
  318. data/node/node_modules/playwright-core/lib/server/android/backendAdb.js +0 -177
  319. data/node/node_modules/playwright-core/lib/server/artifact.js +0 -127
  320. data/node/node_modules/playwright-core/lib/server/bidi/bidiBrowser.js +0 -549
  321. data/node/node_modules/playwright-core/lib/server/bidi/bidiChromium.js +0 -148
  322. data/node/node_modules/playwright-core/lib/server/bidi/bidiConnection.js +0 -213
  323. data/node/node_modules/playwright-core/lib/server/bidi/bidiDeserializer.js +0 -116
  324. data/node/node_modules/playwright-core/lib/server/bidi/bidiExecutionContext.js +0 -267
  325. data/node/node_modules/playwright-core/lib/server/bidi/bidiFirefox.js +0 -128
  326. data/node/node_modules/playwright-core/lib/server/bidi/bidiInput.js +0 -146
  327. data/node/node_modules/playwright-core/lib/server/bidi/bidiNetworkManager.js +0 -383
  328. data/node/node_modules/playwright-core/lib/server/bidi/bidiOverCdp.js +0 -102
  329. data/node/node_modules/playwright-core/lib/server/bidi/bidiPage.js +0 -583
  330. data/node/node_modules/playwright-core/lib/server/bidi/bidiPdf.js +0 -106
  331. data/node/node_modules/playwright-core/lib/server/bidi/third_party/bidiCommands.d.js +0 -22
  332. data/node/node_modules/playwright-core/lib/server/bidi/third_party/bidiKeyboard.js +0 -256
  333. data/node/node_modules/playwright-core/lib/server/bidi/third_party/bidiProtocol.js +0 -24
  334. data/node/node_modules/playwright-core/lib/server/bidi/third_party/bidiProtocolCore.js +0 -180
  335. data/node/node_modules/playwright-core/lib/server/bidi/third_party/bidiProtocolPermissions.js +0 -42
  336. data/node/node_modules/playwright-core/lib/server/bidi/third_party/bidiSerializer.js +0 -148
  337. data/node/node_modules/playwright-core/lib/server/bidi/third_party/firefoxPrefs.js +0 -259
  338. data/node/node_modules/playwright-core/lib/server/browser.js +0 -149
  339. data/node/node_modules/playwright-core/lib/server/browserContext.js +0 -702
  340. data/node/node_modules/playwright-core/lib/server/browserType.js +0 -336
  341. data/node/node_modules/playwright-core/lib/server/callLog.js +0 -82
  342. data/node/node_modules/playwright-core/lib/server/chromium/appIcon.png +0 -0
  343. data/node/node_modules/playwright-core/lib/server/chromium/chromium.js +0 -395
  344. data/node/node_modules/playwright-core/lib/server/chromium/chromiumSwitches.js +0 -104
  345. data/node/node_modules/playwright-core/lib/server/chromium/crBrowser.js +0 -511
  346. data/node/node_modules/playwright-core/lib/server/chromium/crConnection.js +0 -197
  347. data/node/node_modules/playwright-core/lib/server/chromium/crCoverage.js +0 -235
  348. data/node/node_modules/playwright-core/lib/server/chromium/crDevTools.js +0 -111
  349. data/node/node_modules/playwright-core/lib/server/chromium/crDragDrop.js +0 -131
  350. data/node/node_modules/playwright-core/lib/server/chromium/crExecutionContext.js +0 -146
  351. data/node/node_modules/playwright-core/lib/server/chromium/crInput.js +0 -187
  352. data/node/node_modules/playwright-core/lib/server/chromium/crNetworkManager.js +0 -707
  353. data/node/node_modules/playwright-core/lib/server/chromium/crPage.js +0 -1001
  354. data/node/node_modules/playwright-core/lib/server/chromium/crPdf.js +0 -121
  355. data/node/node_modules/playwright-core/lib/server/chromium/crProtocolHelper.js +0 -145
  356. data/node/node_modules/playwright-core/lib/server/chromium/crServiceWorker.js +0 -136
  357. data/node/node_modules/playwright-core/lib/server/chromium/defaultFontFamilies.js +0 -162
  358. data/node/node_modules/playwright-core/lib/server/chromium/protocol.d.js +0 -16
  359. data/node/node_modules/playwright-core/lib/server/clock.js +0 -149
  360. data/node/node_modules/playwright-core/lib/server/codegen/csharp.js +0 -327
  361. data/node/node_modules/playwright-core/lib/server/codegen/java.js +0 -274
  362. data/node/node_modules/playwright-core/lib/server/codegen/javascript.js +0 -247
  363. data/node/node_modules/playwright-core/lib/server/codegen/jsonl.js +0 -52
  364. data/node/node_modules/playwright-core/lib/server/codegen/language.js +0 -132
  365. data/node/node_modules/playwright-core/lib/server/codegen/languages.js +0 -68
  366. data/node/node_modules/playwright-core/lib/server/codegen/python.js +0 -279
  367. data/node/node_modules/playwright-core/lib/server/codegen/types.js +0 -16
  368. data/node/node_modules/playwright-core/lib/server/console.js +0 -57
  369. data/node/node_modules/playwright-core/lib/server/cookieStore.js +0 -206
  370. data/node/node_modules/playwright-core/lib/server/debugController.js +0 -191
  371. data/node/node_modules/playwright-core/lib/server/debugger.js +0 -119
  372. data/node/node_modules/playwright-core/lib/server/deviceDescriptors.js +0 -39
  373. data/node/node_modules/playwright-core/lib/server/deviceDescriptorsSource.json +0 -1779
  374. data/node/node_modules/playwright-core/lib/server/dialog.js +0 -116
  375. data/node/node_modules/playwright-core/lib/server/dispatchers/androidDispatcher.js +0 -325
  376. data/node/node_modules/playwright-core/lib/server/dispatchers/artifactDispatcher.js +0 -118
  377. data/node/node_modules/playwright-core/lib/server/dispatchers/browserContextDispatcher.js +0 -384
  378. data/node/node_modules/playwright-core/lib/server/dispatchers/browserDispatcher.js +0 -118
  379. data/node/node_modules/playwright-core/lib/server/dispatchers/browserTypeDispatcher.js +0 -64
  380. data/node/node_modules/playwright-core/lib/server/dispatchers/cdpSessionDispatcher.js +0 -44
  381. data/node/node_modules/playwright-core/lib/server/dispatchers/debugControllerDispatcher.js +0 -78
  382. data/node/node_modules/playwright-core/lib/server/dispatchers/dialogDispatcher.js +0 -47
  383. data/node/node_modules/playwright-core/lib/server/dispatchers/dispatcher.js +0 -364
  384. data/node/node_modules/playwright-core/lib/server/dispatchers/electronDispatcher.js +0 -89
  385. data/node/node_modules/playwright-core/lib/server/dispatchers/elementHandlerDispatcher.js +0 -181
  386. data/node/node_modules/playwright-core/lib/server/dispatchers/frameDispatcher.js +0 -227
  387. data/node/node_modules/playwright-core/lib/server/dispatchers/jsHandleDispatcher.js +0 -85
  388. data/node/node_modules/playwright-core/lib/server/dispatchers/jsonPipeDispatcher.js +0 -58
  389. data/node/node_modules/playwright-core/lib/server/dispatchers/localUtilsDispatcher.js +0 -149
  390. data/node/node_modules/playwright-core/lib/server/dispatchers/networkDispatchers.js +0 -213
  391. data/node/node_modules/playwright-core/lib/server/dispatchers/pageAgentDispatcher.js +0 -96
  392. data/node/node_modules/playwright-core/lib/server/dispatchers/pageDispatcher.js +0 -393
  393. data/node/node_modules/playwright-core/lib/server/dispatchers/playwrightDispatcher.js +0 -108
  394. data/node/node_modules/playwright-core/lib/server/dispatchers/streamDispatcher.js +0 -67
  395. data/node/node_modules/playwright-core/lib/server/dispatchers/tracingDispatcher.js +0 -68
  396. data/node/node_modules/playwright-core/lib/server/dispatchers/webSocketRouteDispatcher.js +0 -165
  397. data/node/node_modules/playwright-core/lib/server/dispatchers/writableStreamDispatcher.js +0 -79
  398. data/node/node_modules/playwright-core/lib/server/dom.js +0 -815
  399. data/node/node_modules/playwright-core/lib/server/download.js +0 -70
  400. data/node/node_modules/playwright-core/lib/server/electron/electron.js +0 -273
  401. data/node/node_modules/playwright-core/lib/server/electron/loader.js +0 -29
  402. data/node/node_modules/playwright-core/lib/server/errors.js +0 -69
  403. data/node/node_modules/playwright-core/lib/server/fetch.js +0 -621
  404. data/node/node_modules/playwright-core/lib/server/fileChooser.js +0 -43
  405. data/node/node_modules/playwright-core/lib/server/fileUploadUtils.js +0 -84
  406. data/node/node_modules/playwright-core/lib/server/firefox/ffBrowser.js +0 -418
  407. data/node/node_modules/playwright-core/lib/server/firefox/ffConnection.js +0 -142
  408. data/node/node_modules/playwright-core/lib/server/firefox/ffExecutionContext.js +0 -150
  409. data/node/node_modules/playwright-core/lib/server/firefox/ffInput.js +0 -159
  410. data/node/node_modules/playwright-core/lib/server/firefox/ffNetworkManager.js +0 -256
  411. data/node/node_modules/playwright-core/lib/server/firefox/ffPage.js +0 -497
  412. data/node/node_modules/playwright-core/lib/server/firefox/firefox.js +0 -114
  413. data/node/node_modules/playwright-core/lib/server/firefox/protocol.d.js +0 -16
  414. data/node/node_modules/playwright-core/lib/server/formData.js +0 -147
  415. data/node/node_modules/playwright-core/lib/server/frameSelectors.js +0 -160
  416. data/node/node_modules/playwright-core/lib/server/frames.js +0 -1471
  417. data/node/node_modules/playwright-core/lib/server/har/harRecorder.js +0 -147
  418. data/node/node_modules/playwright-core/lib/server/har/harTracer.js +0 -607
  419. data/node/node_modules/playwright-core/lib/server/harBackend.js +0 -157
  420. data/node/node_modules/playwright-core/lib/server/helper.js +0 -96
  421. data/node/node_modules/playwright-core/lib/server/index.js +0 -58
  422. data/node/node_modules/playwright-core/lib/server/input.js +0 -277
  423. data/node/node_modules/playwright-core/lib/server/instrumentation.js +0 -72
  424. data/node/node_modules/playwright-core/lib/server/javascript.js +0 -291
  425. data/node/node_modules/playwright-core/lib/server/launchApp.js +0 -128
  426. data/node/node_modules/playwright-core/lib/server/localUtils.js +0 -214
  427. data/node/node_modules/playwright-core/lib/server/macEditingCommands.js +0 -143
  428. data/node/node_modules/playwright-core/lib/server/network.js +0 -667
  429. data/node/node_modules/playwright-core/lib/server/page.js +0 -830
  430. data/node/node_modules/playwright-core/lib/server/pipeTransport.js +0 -89
  431. data/node/node_modules/playwright-core/lib/server/playwright.js +0 -69
  432. data/node/node_modules/playwright-core/lib/server/progress.js +0 -132
  433. data/node/node_modules/playwright-core/lib/server/protocolError.js +0 -52
  434. data/node/node_modules/playwright-core/lib/server/recorder/chat.js +0 -161
  435. data/node/node_modules/playwright-core/lib/server/recorder/recorderApp.js +0 -366
  436. data/node/node_modules/playwright-core/lib/server/recorder/recorderRunner.js +0 -138
  437. data/node/node_modules/playwright-core/lib/server/recorder/recorderSignalProcessor.js +0 -83
  438. data/node/node_modules/playwright-core/lib/server/recorder/recorderUtils.js +0 -157
  439. data/node/node_modules/playwright-core/lib/server/recorder/throttledFile.js +0 -57
  440. data/node/node_modules/playwright-core/lib/server/recorder.js +0 -499
  441. data/node/node_modules/playwright-core/lib/server/registry/browserFetcher.js +0 -177
  442. data/node/node_modules/playwright-core/lib/server/registry/dependencies.js +0 -371
  443. data/node/node_modules/playwright-core/lib/server/registry/index.js +0 -1422
  444. data/node/node_modules/playwright-core/lib/server/registry/nativeDeps.js +0 -1280
  445. data/node/node_modules/playwright-core/lib/server/registry/oopDownloadBrowserMain.js +0 -127
  446. data/node/node_modules/playwright-core/lib/server/screencast.js +0 -190
  447. data/node/node_modules/playwright-core/lib/server/screenshotter.js +0 -333
  448. data/node/node_modules/playwright-core/lib/server/selectors.js +0 -112
  449. data/node/node_modules/playwright-core/lib/server/socksClientCertificatesInterceptor.js +0 -383
  450. data/node/node_modules/playwright-core/lib/server/socksInterceptor.js +0 -95
  451. data/node/node_modules/playwright-core/lib/server/trace/recorder/snapshotter.js +0 -147
  452. data/node/node_modules/playwright-core/lib/server/trace/recorder/snapshotterInjected.js +0 -561
  453. data/node/node_modules/playwright-core/lib/server/trace/recorder/tracing.js +0 -604
  454. data/node/node_modules/playwright-core/lib/server/trace/viewer/traceParser.js +0 -72
  455. data/node/node_modules/playwright-core/lib/server/trace/viewer/traceViewer.js +0 -245
  456. data/node/node_modules/playwright-core/lib/server/transport.js +0 -181
  457. data/node/node_modules/playwright-core/lib/server/types.js +0 -28
  458. data/node/node_modules/playwright-core/lib/server/usKeyboardLayout.js +0 -145
  459. data/node/node_modules/playwright-core/lib/server/utils/ascii.js +0 -44
  460. data/node/node_modules/playwright-core/lib/server/utils/comparators.js +0 -139
  461. data/node/node_modules/playwright-core/lib/server/utils/crypto.js +0 -216
  462. data/node/node_modules/playwright-core/lib/server/utils/debug.js +0 -42
  463. data/node/node_modules/playwright-core/lib/server/utils/debugLogger.js +0 -122
  464. data/node/node_modules/playwright-core/lib/server/utils/env.js +0 -73
  465. data/node/node_modules/playwright-core/lib/server/utils/eventsHelper.js +0 -39
  466. data/node/node_modules/playwright-core/lib/server/utils/expectUtils.js +0 -123
  467. data/node/node_modules/playwright-core/lib/server/utils/fileUtils.js +0 -191
  468. data/node/node_modules/playwright-core/lib/server/utils/happyEyeballs.js +0 -207
  469. data/node/node_modules/playwright-core/lib/server/utils/hostPlatform.js +0 -123
  470. data/node/node_modules/playwright-core/lib/server/utils/httpServer.js +0 -203
  471. data/node/node_modules/playwright-core/lib/server/utils/imageUtils.js +0 -141
  472. data/node/node_modules/playwright-core/lib/server/utils/image_tools/colorUtils.js +0 -89
  473. data/node/node_modules/playwright-core/lib/server/utils/image_tools/compare.js +0 -109
  474. data/node/node_modules/playwright-core/lib/server/utils/image_tools/imageChannel.js +0 -78
  475. data/node/node_modules/playwright-core/lib/server/utils/image_tools/stats.js +0 -102
  476. data/node/node_modules/playwright-core/lib/server/utils/linuxUtils.js +0 -71
  477. data/node/node_modules/playwright-core/lib/server/utils/network.js +0 -242
  478. data/node/node_modules/playwright-core/lib/server/utils/nodePlatform.js +0 -154
  479. data/node/node_modules/playwright-core/lib/server/utils/pipeTransport.js +0 -84
  480. data/node/node_modules/playwright-core/lib/server/utils/processLauncher.js +0 -241
  481. data/node/node_modules/playwright-core/lib/server/utils/profiler.js +0 -65
  482. data/node/node_modules/playwright-core/lib/server/utils/socksProxy.js +0 -511
  483. data/node/node_modules/playwright-core/lib/server/utils/spawnAsync.js +0 -41
  484. data/node/node_modules/playwright-core/lib/server/utils/task.js +0 -51
  485. data/node/node_modules/playwright-core/lib/server/utils/userAgent.js +0 -98
  486. data/node/node_modules/playwright-core/lib/server/utils/wsServer.js +0 -121
  487. data/node/node_modules/playwright-core/lib/server/utils/zipFile.js +0 -74
  488. data/node/node_modules/playwright-core/lib/server/utils/zones.js +0 -57
  489. data/node/node_modules/playwright-core/lib/server/videoRecorder.js +0 -124
  490. data/node/node_modules/playwright-core/lib/server/webkit/protocol.d.js +0 -16
  491. data/node/node_modules/playwright-core/lib/server/webkit/webkit.js +0 -108
  492. data/node/node_modules/playwright-core/lib/server/webkit/wkBrowser.js +0 -335
  493. data/node/node_modules/playwright-core/lib/server/webkit/wkConnection.js +0 -144
  494. data/node/node_modules/playwright-core/lib/server/webkit/wkExecutionContext.js +0 -154
  495. data/node/node_modules/playwright-core/lib/server/webkit/wkInput.js +0 -181
  496. data/node/node_modules/playwright-core/lib/server/webkit/wkInterceptableRequest.js +0 -197
  497. data/node/node_modules/playwright-core/lib/server/webkit/wkPage.js +0 -1158
  498. data/node/node_modules/playwright-core/lib/server/webkit/wkProvisionalPage.js +0 -83
  499. data/node/node_modules/playwright-core/lib/server/webkit/wkWorkers.js +0 -105
  500. data/node/node_modules/playwright-core/lib/third_party/pixelmatch.js +0 -255
  501. data/node/node_modules/playwright-core/lib/utils/isomorphic/ariaSnapshot.js +0 -455
  502. data/node/node_modules/playwright-core/lib/utils/isomorphic/assert.js +0 -31
  503. data/node/node_modules/playwright-core/lib/utils/isomorphic/colors.js +0 -72
  504. data/node/node_modules/playwright-core/lib/utils/isomorphic/cssParser.js +0 -245
  505. data/node/node_modules/playwright-core/lib/utils/isomorphic/cssTokenizer.js +0 -1051
  506. data/node/node_modules/playwright-core/lib/utils/isomorphic/headers.js +0 -53
  507. data/node/node_modules/playwright-core/lib/utils/isomorphic/locatorGenerators.js +0 -689
  508. data/node/node_modules/playwright-core/lib/utils/isomorphic/locatorParser.js +0 -176
  509. data/node/node_modules/playwright-core/lib/utils/isomorphic/locatorUtils.js +0 -81
  510. data/node/node_modules/playwright-core/lib/utils/isomorphic/lruCache.js +0 -51
  511. data/node/node_modules/playwright-core/lib/utils/isomorphic/manualPromise.js +0 -114
  512. data/node/node_modules/playwright-core/lib/utils/isomorphic/mimeType.js +0 -459
  513. data/node/node_modules/playwright-core/lib/utils/isomorphic/multimap.js +0 -80
  514. data/node/node_modules/playwright-core/lib/utils/isomorphic/protocolFormatter.js +0 -81
  515. data/node/node_modules/playwright-core/lib/utils/isomorphic/protocolMetainfo.js +0 -330
  516. data/node/node_modules/playwright-core/lib/utils/isomorphic/rtti.js +0 -43
  517. data/node/node_modules/playwright-core/lib/utils/isomorphic/selectorParser.js +0 -386
  518. data/node/node_modules/playwright-core/lib/utils/isomorphic/semaphore.js +0 -54
  519. data/node/node_modules/playwright-core/lib/utils/isomorphic/stackTrace.js +0 -158
  520. data/node/node_modules/playwright-core/lib/utils/isomorphic/stringUtils.js +0 -204
  521. data/node/node_modules/playwright-core/lib/utils/isomorphic/time.js +0 -49
  522. data/node/node_modules/playwright-core/lib/utils/isomorphic/timeoutRunner.js +0 -66
  523. data/node/node_modules/playwright-core/lib/utils/isomorphic/trace/entries.js +0 -16
  524. data/node/node_modules/playwright-core/lib/utils/isomorphic/trace/snapshotRenderer.js +0 -499
  525. data/node/node_modules/playwright-core/lib/utils/isomorphic/trace/snapshotServer.js +0 -120
  526. data/node/node_modules/playwright-core/lib/utils/isomorphic/trace/snapshotStorage.js +0 -89
  527. data/node/node_modules/playwright-core/lib/utils/isomorphic/trace/traceLoader.js +0 -131
  528. data/node/node_modules/playwright-core/lib/utils/isomorphic/trace/traceModel.js +0 -365
  529. data/node/node_modules/playwright-core/lib/utils/isomorphic/trace/traceModernizer.js +0 -400
  530. data/node/node_modules/playwright-core/lib/utils/isomorphic/trace/versions/traceV3.js +0 -16
  531. data/node/node_modules/playwright-core/lib/utils/isomorphic/trace/versions/traceV4.js +0 -16
  532. data/node/node_modules/playwright-core/lib/utils/isomorphic/trace/versions/traceV5.js +0 -16
  533. data/node/node_modules/playwright-core/lib/utils/isomorphic/trace/versions/traceV6.js +0 -16
  534. data/node/node_modules/playwright-core/lib/utils/isomorphic/trace/versions/traceV7.js +0 -16
  535. data/node/node_modules/playwright-core/lib/utils/isomorphic/trace/versions/traceV8.js +0 -16
  536. data/node/node_modules/playwright-core/lib/utils/isomorphic/traceUtils.js +0 -58
  537. data/node/node_modules/playwright-core/lib/utils/isomorphic/types.js +0 -16
  538. data/node/node_modules/playwright-core/lib/utils/isomorphic/urlMatch.js +0 -190
  539. data/node/node_modules/playwright-core/lib/utils/isomorphic/utilityScriptSerializers.js +0 -251
  540. data/node/node_modules/playwright-core/lib/utils/isomorphic/yaml.js +0 -84
  541. data/node/node_modules/playwright-core/lib/utils.js +0 -111
  542. data/node/node_modules/playwright-core/lib/utilsBundle.js +0 -109
  543. data/node/node_modules/playwright-core/lib/utilsBundleImpl/index.js +0 -218
  544. data/node/node_modules/playwright-core/lib/utilsBundleImpl/xdg-open +0 -1066
  545. data/node/node_modules/playwright-core/lib/vite/htmlReport/index.html +0 -84
  546. data/node/node_modules/playwright-core/lib/vite/recorder/assets/codeMirrorModule-DYBRYzYX.css +0 -1
  547. data/node/node_modules/playwright-core/lib/vite/recorder/assets/codeMirrorModule-DadYNm1I.js +0 -32
  548. data/node/node_modules/playwright-core/lib/vite/recorder/assets/codicon-DCmgc-ay.ttf +0 -0
  549. data/node/node_modules/playwright-core/lib/vite/recorder/assets/index-BSjZa4pk.css +0 -1
  550. data/node/node_modules/playwright-core/lib/vite/recorder/assets/index-BhTWtUlo.js +0 -193
  551. data/node/node_modules/playwright-core/lib/vite/recorder/index.html +0 -29
  552. data/node/node_modules/playwright-core/lib/vite/recorder/playwright-logo.svg +0 -9
  553. data/node/node_modules/playwright-core/lib/vite/traceViewer/assets/codeMirrorModule-a5XoALAZ.js +0 -32
  554. data/node/node_modules/playwright-core/lib/vite/traceViewer/assets/defaultSettingsView-CJSZINFr.js +0 -266
  555. data/node/node_modules/playwright-core/lib/vite/traceViewer/assets/xtermModule-CsJ4vdCR.js +0 -9
  556. data/node/node_modules/playwright-core/lib/vite/traceViewer/codeMirrorModule.DYBRYzYX.css +0 -1
  557. data/node/node_modules/playwright-core/lib/vite/traceViewer/codicon.DCmgc-ay.ttf +0 -0
  558. data/node/node_modules/playwright-core/lib/vite/traceViewer/defaultSettingsView.7ch9cixO.css +0 -1
  559. data/node/node_modules/playwright-core/lib/vite/traceViewer/index.BVu7tZDe.css +0 -1
  560. data/node/node_modules/playwright-core/lib/vite/traceViewer/index.Bk2uYQRV.js +0 -2
  561. data/node/node_modules/playwright-core/lib/vite/traceViewer/index.html +0 -43
  562. data/node/node_modules/playwright-core/lib/vite/traceViewer/manifest.webmanifest +0 -16
  563. data/node/node_modules/playwright-core/lib/vite/traceViewer/playwright-logo.svg +0 -9
  564. data/node/node_modules/playwright-core/lib/vite/traceViewer/snapshot.html +0 -21
  565. data/node/node_modules/playwright-core/lib/vite/traceViewer/sw.bundle.js +0 -5
  566. data/node/node_modules/playwright-core/lib/vite/traceViewer/uiMode.Btcz36p_.css +0 -1
  567. data/node/node_modules/playwright-core/lib/vite/traceViewer/uiMode.CQJ9SCIQ.js +0 -5
  568. data/node/node_modules/playwright-core/lib/vite/traceViewer/uiMode.html +0 -17
  569. data/node/node_modules/playwright-core/lib/vite/traceViewer/xtermModule.DYP7pi_n.css +0 -32
  570. data/node/node_modules/playwright-core/lib/zipBundle.js +0 -34
  571. data/node/node_modules/playwright-core/lib/zipBundleImpl.js +0 -5
  572. data/node/node_modules/playwright-core/package.json +0 -43
  573. data/node/node_modules/playwright-core/types/protocol.d.ts +0 -23824
  574. data/node/node_modules/playwright-core/types/structs.d.ts +0 -45
  575. data/node/node_modules/playwright-core/types/types.d.ts +0 -22843
  576. data/spec/rubycrawl_spec.rb +0 -51
  577. data/spec/spec_helper.rb +0 -11
@@ -1,1422 +0,0 @@
1
- "use strict";
2
- var __create = Object.create;
3
- var __defProp = Object.defineProperty;
4
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
- var __getOwnPropNames = Object.getOwnPropertyNames;
6
- var __getProtoOf = Object.getPrototypeOf;
7
- var __hasOwnProp = Object.prototype.hasOwnProperty;
8
- var __export = (target, all) => {
9
- for (var name in all)
10
- __defProp(target, name, { get: all[name], enumerable: true });
11
- };
12
- var __copyProps = (to, from, except, desc) => {
13
- if (from && typeof from === "object" || typeof from === "function") {
14
- for (let key of __getOwnPropNames(from))
15
- if (!__hasOwnProp.call(to, key) && key !== except)
16
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
17
- }
18
- return to;
19
- };
20
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
- // If the importer is in node compatibility mode or this is not an ESM
22
- // file that has been converted to a CommonJS file using a Babel-
23
- // compatible transform (i.e. "__esModule" has not been set), then set
24
- // "default" to the CommonJS "module.exports" for node compatibility.
25
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
- mod
27
- ));
28
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
- var registry_exports = {};
30
- __export(registry_exports, {
31
- Registry: () => Registry,
32
- browserDirectoryToMarkerFilePath: () => browserDirectoryToMarkerFilePath,
33
- buildPlaywrightCLICommand: () => buildPlaywrightCLICommand,
34
- findChromiumChannelBestEffort: () => findChromiumChannelBestEffort,
35
- installBrowsersForNpmInstall: () => installBrowsersForNpmInstall,
36
- registry: () => registry,
37
- registryDirectory: () => registryDirectory,
38
- writeDockerVersion: () => import_dependencies3.writeDockerVersion
39
- });
40
- module.exports = __toCommonJS(registry_exports);
41
- var import_fs = __toESM(require("fs"));
42
- var import_os = __toESM(require("os"));
43
- var import_path = __toESM(require("path"));
44
- var util = __toESM(require("util"));
45
- var import_browserFetcher = require("./browserFetcher");
46
- var import_dependencies = require("./dependencies");
47
- var import_dependencies2 = require("./dependencies");
48
- var import_utils = require("../../utils");
49
- var import_ascii = require("../utils/ascii");
50
- var import_debugLogger = require("../utils/debugLogger");
51
- var import_hostPlatform = require("../utils/hostPlatform");
52
- var import_network = require("../utils/network");
53
- var import_spawnAsync = require("../utils/spawnAsync");
54
- var import_userAgent = require("../utils/userAgent");
55
- var import_utilsBundle = require("../../utilsBundle");
56
- var import_fileUtils = require("../utils/fileUtils");
57
- var import_dependencies3 = require("./dependencies");
58
- const PACKAGE_PATH = import_path.default.join(__dirname, "..", "..", "..");
59
- const BIN_PATH = import_path.default.join(__dirname, "..", "..", "..", "bin");
60
- const PLAYWRIGHT_CDN_MIRRORS = [
61
- "https://cdn.playwright.dev/dbazure/download/playwright",
62
- // ESRP CDN
63
- "https://playwright.download.prss.microsoft.com/dbazure/download/playwright",
64
- // Directly hit ESRP CDN
65
- "https://cdn.playwright.dev"
66
- // Hit the Storage Bucket directly
67
- ];
68
- if (process.env.PW_TEST_CDN_THAT_SHOULD_WORK) {
69
- for (let i = 0; i < PLAYWRIGHT_CDN_MIRRORS.length; i++) {
70
- const cdn = PLAYWRIGHT_CDN_MIRRORS[i];
71
- if (cdn !== process.env.PW_TEST_CDN_THAT_SHOULD_WORK) {
72
- const parsedCDN = new URL(cdn);
73
- parsedCDN.hostname = parsedCDN.hostname + ".does-not-resolve.playwright.dev";
74
- PLAYWRIGHT_CDN_MIRRORS[i] = parsedCDN.toString();
75
- }
76
- }
77
- }
78
- const EXECUTABLE_PATHS = {
79
- "chromium": {
80
- "<unknown>": void 0,
81
- "linux-x64": ["chrome-linux64", "chrome"],
82
- "linux-arm64": ["chrome-linux", "chrome"],
83
- // non-cft build
84
- "mac-x64": ["chrome-mac-x64", "Google Chrome for Testing.app", "Contents", "MacOS", "Google Chrome for Testing"],
85
- "mac-arm64": ["chrome-mac-arm64", "Google Chrome for Testing.app", "Contents", "MacOS", "Google Chrome for Testing"],
86
- "win-x64": ["chrome-win64", "chrome.exe"]
87
- },
88
- "chromium-headless-shell": {
89
- "<unknown>": void 0,
90
- "linux-x64": ["chrome-headless-shell-linux64", "chrome-headless-shell"],
91
- "linux-arm64": ["chrome-linux", "headless_shell"],
92
- // non-cft build
93
- "mac-x64": ["chrome-headless-shell-mac-x64", "chrome-headless-shell"],
94
- "mac-arm64": ["chrome-headless-shell-mac-arm64", "chrome-headless-shell"],
95
- "win-x64": ["chrome-headless-shell-win64", "chrome-headless-shell.exe"]
96
- },
97
- "chromium-tip-of-tree": {
98
- "<unknown>": void 0,
99
- "linux-x64": ["chrome-linux64", "chrome"],
100
- "linux-arm64": ["chrome-linux", "chrome"],
101
- // non-cft build
102
- "mac-x64": ["chrome-mac-x64", "Google Chrome for Testing.app", "Contents", "MacOS", "Google Chrome for Testing"],
103
- "mac-arm64": ["chrome-mac-arm64", "Google Chrome for Testing.app", "Contents", "MacOS", "Google Chrome for Testing"],
104
- "win-x64": ["chrome-win64", "chrome.exe"]
105
- },
106
- "chromium-tip-of-tree-headless-shell": {
107
- "<unknown>": void 0,
108
- "linux-x64": ["chrome-headless-shell-linux64", "chrome-headless-shell"],
109
- "linux-arm64": ["chrome-linux", "headless_shell"],
110
- // non-cft build
111
- "mac-x64": ["chrome-headless-shell-mac-x64", "chrome-headless-shell"],
112
- "mac-arm64": ["chrome-headless-shell-mac-arm64", "chrome-headless-shell"],
113
- "win-x64": ["chrome-headless-shell-win64", "chrome-headless-shell.exe"]
114
- },
115
- "firefox": {
116
- "<unknown>": void 0,
117
- "linux-x64": ["firefox", "firefox"],
118
- "linux-arm64": ["firefox", "firefox"],
119
- "mac-x64": ["firefox", "Nightly.app", "Contents", "MacOS", "firefox"],
120
- "mac-arm64": ["firefox", "Nightly.app", "Contents", "MacOS", "firefox"],
121
- "win-x64": ["firefox", "firefox.exe"]
122
- },
123
- "webkit": {
124
- "<unknown>": void 0,
125
- "linux-x64": ["pw_run.sh"],
126
- "linux-arm64": ["pw_run.sh"],
127
- "mac-x64": ["pw_run.sh"],
128
- "mac-arm64": ["pw_run.sh"],
129
- "win-x64": ["Playwright.exe"]
130
- },
131
- "ffmpeg": {
132
- "<unknown>": void 0,
133
- "linux-x64": ["ffmpeg-linux"],
134
- "linux-arm64": ["ffmpeg-linux"],
135
- "mac-x64": ["ffmpeg-mac"],
136
- "mac-arm64": ["ffmpeg-mac"],
137
- "win-x64": ["ffmpeg-win64.exe"]
138
- },
139
- "winldd": {
140
- "<unknown>": void 0,
141
- "linux-x64": void 0,
142
- "linux-arm64": void 0,
143
- "mac-x64": void 0,
144
- "mac-arm64": void 0,
145
- "win-x64": ["PrintDeps.exe"]
146
- }
147
- };
148
- function cftUrl(suffix) {
149
- return ({ browserVersion }) => {
150
- return {
151
- path: `${browserVersion}/${suffix}`,
152
- mirrors: [
153
- "https://cdn.playwright.dev/chrome-for-testing-public"
154
- ]
155
- };
156
- };
157
- }
158
- const DOWNLOAD_PATHS = {
159
- "chromium": {
160
- "<unknown>": void 0,
161
- "ubuntu18.04-x64": void 0,
162
- "ubuntu20.04-x64": cftUrl("linux64/chrome-linux64.zip"),
163
- "ubuntu22.04-x64": cftUrl("linux64/chrome-linux64.zip"),
164
- "ubuntu24.04-x64": cftUrl("linux64/chrome-linux64.zip"),
165
- "ubuntu18.04-arm64": void 0,
166
- "ubuntu20.04-arm64": "builds/chromium/%s/chromium-linux-arm64.zip",
167
- "ubuntu22.04-arm64": "builds/chromium/%s/chromium-linux-arm64.zip",
168
- "ubuntu24.04-arm64": "builds/chromium/%s/chromium-linux-arm64.zip",
169
- "debian11-x64": cftUrl("linux64/chrome-linux64.zip"),
170
- "debian11-arm64": "builds/chromium/%s/chromium-linux-arm64.zip",
171
- "debian12-x64": cftUrl("linux64/chrome-linux64.zip"),
172
- "debian12-arm64": "builds/chromium/%s/chromium-linux-arm64.zip",
173
- "debian13-x64": cftUrl("linux64/chrome-linux64.zip"),
174
- "debian13-arm64": "builds/chromium/%s/chromium-linux-arm64.zip",
175
- "mac10.13": cftUrl("mac-x64/chrome-mac-x64.zip"),
176
- "mac10.14": cftUrl("mac-x64/chrome-mac-x64.zip"),
177
- "mac10.15": cftUrl("mac-x64/chrome-mac-x64.zip"),
178
- "mac11": cftUrl("mac-x64/chrome-mac-x64.zip"),
179
- "mac11-arm64": cftUrl("mac-arm64/chrome-mac-arm64.zip"),
180
- "mac12": cftUrl("mac-x64/chrome-mac-x64.zip"),
181
- "mac12-arm64": cftUrl("mac-arm64/chrome-mac-arm64.zip"),
182
- "mac13": cftUrl("mac-x64/chrome-mac-x64.zip"),
183
- "mac13-arm64": cftUrl("mac-arm64/chrome-mac-arm64.zip"),
184
- "mac14": cftUrl("mac-x64/chrome-mac-x64.zip"),
185
- "mac14-arm64": cftUrl("mac-arm64/chrome-mac-arm64.zip"),
186
- "mac15": cftUrl("mac-x64/chrome-mac-x64.zip"),
187
- "mac15-arm64": cftUrl("mac-arm64/chrome-mac-arm64.zip"),
188
- "win64": cftUrl("win64/chrome-win64.zip")
189
- },
190
- "chromium-headless-shell": {
191
- "<unknown>": void 0,
192
- "ubuntu18.04-x64": void 0,
193
- "ubuntu20.04-x64": cftUrl("linux64/chrome-headless-shell-linux64.zip"),
194
- "ubuntu22.04-x64": cftUrl("linux64/chrome-headless-shell-linux64.zip"),
195
- "ubuntu24.04-x64": cftUrl("linux64/chrome-headless-shell-linux64.zip"),
196
- "ubuntu18.04-arm64": void 0,
197
- "ubuntu20.04-arm64": "builds/chromium/%s/chromium-headless-shell-linux-arm64.zip",
198
- "ubuntu22.04-arm64": "builds/chromium/%s/chromium-headless-shell-linux-arm64.zip",
199
- "ubuntu24.04-arm64": "builds/chromium/%s/chromium-headless-shell-linux-arm64.zip",
200
- "debian11-x64": cftUrl("linux64/chrome-headless-shell-linux64.zip"),
201
- "debian11-arm64": "builds/chromium/%s/chromium-headless-shell-linux-arm64.zip",
202
- "debian12-x64": cftUrl("linux64/chrome-headless-shell-linux64.zip"),
203
- "debian12-arm64": "builds/chromium/%s/chromium-headless-shell-linux-arm64.zip",
204
- "debian13-x64": cftUrl("linux64/chrome-headless-shell-linux64.zip"),
205
- "debian13-arm64": "builds/chromium/%s/chromium-headless-shell-linux-arm64.zip",
206
- "mac10.13": void 0,
207
- "mac10.14": void 0,
208
- "mac10.15": void 0,
209
- "mac11": cftUrl("mac-x64/chrome-headless-shell-mac-x64.zip"),
210
- "mac11-arm64": cftUrl("mac-arm64/chrome-headless-shell-mac-arm64.zip"),
211
- "mac12": cftUrl("mac-x64/chrome-headless-shell-mac-x64.zip"),
212
- "mac12-arm64": cftUrl("mac-arm64/chrome-headless-shell-mac-arm64.zip"),
213
- "mac13": cftUrl("mac-x64/chrome-headless-shell-mac-x64.zip"),
214
- "mac13-arm64": cftUrl("mac-arm64/chrome-headless-shell-mac-arm64.zip"),
215
- "mac14": cftUrl("mac-x64/chrome-headless-shell-mac-x64.zip"),
216
- "mac14-arm64": cftUrl("mac-arm64/chrome-headless-shell-mac-arm64.zip"),
217
- "mac15": cftUrl("mac-x64/chrome-headless-shell-mac-x64.zip"),
218
- "mac15-arm64": cftUrl("mac-arm64/chrome-headless-shell-mac-arm64.zip"),
219
- "win64": cftUrl("win64/chrome-headless-shell-win64.zip")
220
- },
221
- "chromium-tip-of-tree": {
222
- "<unknown>": void 0,
223
- "ubuntu18.04-x64": void 0,
224
- "ubuntu20.04-x64": cftUrl("linux64/chrome-linux64.zip"),
225
- "ubuntu22.04-x64": cftUrl("linux64/chrome-linux64.zip"),
226
- "ubuntu24.04-x64": cftUrl("linux64/chrome-linux64.zip"),
227
- "ubuntu18.04-arm64": void 0,
228
- "ubuntu20.04-arm64": "builds/chromium-tip-of-tree/%s/chromium-tip-of-tree-linux-arm64.zip",
229
- "ubuntu22.04-arm64": "builds/chromium-tip-of-tree/%s/chromium-tip-of-tree-linux-arm64.zip",
230
- "ubuntu24.04-arm64": "builds/chromium-tip-of-tree/%s/chromium-tip-of-tree-linux-arm64.zip",
231
- "debian11-x64": cftUrl("linux64/chrome-linux64.zip"),
232
- "debian11-arm64": "builds/chromium-tip-of-tree/%s/chromium-tip-of-tree-linux-arm64.zip",
233
- "debian12-x64": cftUrl("linux64/chrome-linux64.zip"),
234
- "debian12-arm64": "builds/chromium-tip-of-tree/%s/chromium-tip-of-tree-linux-arm64.zip",
235
- "debian13-x64": cftUrl("linux64/chrome-linux64.zip"),
236
- "debian13-arm64": "builds/chromium-tip-of-tree/%s/chromium-tip-of-tree-linux-arm64.zip",
237
- "mac10.13": cftUrl("mac-x64/chrome-mac-x64.zip"),
238
- "mac10.14": cftUrl("mac-x64/chrome-mac-x64.zip"),
239
- "mac10.15": cftUrl("mac-x64/chrome-mac-x64.zip"),
240
- "mac11": cftUrl("mac-x64/chrome-mac-x64.zip"),
241
- "mac11-arm64": cftUrl("mac-arm64/chrome-mac-arm64.zip"),
242
- "mac12": cftUrl("mac-x64/chrome-mac-x64.zip"),
243
- "mac12-arm64": cftUrl("mac-arm64/chrome-mac-arm64.zip"),
244
- "mac13": cftUrl("mac-x64/chrome-mac-x64.zip"),
245
- "mac13-arm64": cftUrl("mac-arm64/chrome-mac-arm64.zip"),
246
- "mac14": cftUrl("mac-x64/chrome-mac-x64.zip"),
247
- "mac14-arm64": cftUrl("mac-arm64/chrome-mac-arm64.zip"),
248
- "mac15": cftUrl("mac-x64/chrome-mac-x64.zip"),
249
- "mac15-arm64": cftUrl("mac-arm64/chrome-mac-arm64.zip"),
250
- "win64": cftUrl("win64/chrome-win64.zip")
251
- },
252
- "chromium-tip-of-tree-headless-shell": {
253
- "<unknown>": void 0,
254
- "ubuntu18.04-x64": void 0,
255
- "ubuntu20.04-x64": cftUrl("linux64/chrome-headless-shell-linux64.zip"),
256
- "ubuntu22.04-x64": cftUrl("linux64/chrome-headless-shell-linux64.zip"),
257
- "ubuntu24.04-x64": cftUrl("linux64/chrome-headless-shell-linux64.zip"),
258
- "ubuntu18.04-arm64": void 0,
259
- "ubuntu20.04-arm64": "builds/chromium-tip-of-tree/%s/chromium-tip-of-tree-headless-shell-linux-arm64.zip",
260
- "ubuntu22.04-arm64": "builds/chromium-tip-of-tree/%s/chromium-tip-of-tree-headless-shell-linux-arm64.zip",
261
- "ubuntu24.04-arm64": "builds/chromium-tip-of-tree/%s/chromium-tip-of-tree-headless-shell-linux-arm64.zip",
262
- "debian11-x64": cftUrl("linux64/chrome-headless-shell-linux64.zip"),
263
- "debian11-arm64": "builds/chromium-tip-of-tree/%s/chromium-tip-of-tree-headless-shell-linux-arm64.zip",
264
- "debian12-x64": cftUrl("linux64/chrome-headless-shell-linux64.zip"),
265
- "debian12-arm64": "builds/chromium-tip-of-tree/%s/chromium-tip-of-tree-headless-shell-linux-arm64.zip",
266
- "debian13-x64": cftUrl("linux64/chrome-headless-shell-linux64.zip"),
267
- "debian13-arm64": "builds/chromium-tip-of-tree/%s/chromium-tip-of-tree-headless-shell-linux-arm64.zip",
268
- "mac10.13": void 0,
269
- "mac10.14": void 0,
270
- "mac10.15": void 0,
271
- "mac11": cftUrl("mac-x64/chrome-headless-shell-mac-x64.zip"),
272
- "mac11-arm64": cftUrl("mac-arm64/chrome-headless-shell-mac-arm64.zip"),
273
- "mac12": cftUrl("mac-x64/chrome-headless-shell-mac-x64.zip"),
274
- "mac12-arm64": cftUrl("mac-arm64/chrome-headless-shell-mac-arm64.zip"),
275
- "mac13": cftUrl("mac-x64/chrome-headless-shell-mac-x64.zip"),
276
- "mac13-arm64": cftUrl("mac-arm64/chrome-headless-shell-mac-arm64.zip"),
277
- "mac14": cftUrl("mac-x64/chrome-headless-shell-mac-x64.zip"),
278
- "mac14-arm64": cftUrl("mac-arm64/chrome-headless-shell-mac-arm64.zip"),
279
- "mac15": cftUrl("mac-x64/chrome-headless-shell-mac-x64.zip"),
280
- "mac15-arm64": cftUrl("mac-arm64/chrome-headless-shell-mac-arm64.zip"),
281
- "win64": cftUrl("win64/chrome-headless-shell-win64.zip")
282
- },
283
- "firefox": {
284
- "<unknown>": void 0,
285
- "ubuntu18.04-x64": void 0,
286
- "ubuntu20.04-x64": "builds/firefox/%s/firefox-ubuntu-20.04.zip",
287
- "ubuntu22.04-x64": "builds/firefox/%s/firefox-ubuntu-22.04.zip",
288
- "ubuntu24.04-x64": "builds/firefox/%s/firefox-ubuntu-24.04.zip",
289
- "ubuntu18.04-arm64": void 0,
290
- "ubuntu20.04-arm64": "builds/firefox/%s/firefox-ubuntu-20.04-arm64.zip",
291
- "ubuntu22.04-arm64": "builds/firefox/%s/firefox-ubuntu-22.04-arm64.zip",
292
- "ubuntu24.04-arm64": "builds/firefox/%s/firefox-ubuntu-24.04-arm64.zip",
293
- "debian11-x64": "builds/firefox/%s/firefox-debian-11.zip",
294
- "debian11-arm64": "builds/firefox/%s/firefox-debian-11-arm64.zip",
295
- "debian12-x64": "builds/firefox/%s/firefox-debian-12.zip",
296
- "debian12-arm64": "builds/firefox/%s/firefox-debian-12-arm64.zip",
297
- "debian13-x64": "builds/firefox/%s/firefox-debian-13.zip",
298
- "debian13-arm64": "builds/firefox/%s/firefox-debian-13-arm64.zip",
299
- "mac10.13": "builds/firefox/%s/firefox-mac.zip",
300
- "mac10.14": "builds/firefox/%s/firefox-mac.zip",
301
- "mac10.15": "builds/firefox/%s/firefox-mac.zip",
302
- "mac11": "builds/firefox/%s/firefox-mac.zip",
303
- "mac11-arm64": "builds/firefox/%s/firefox-mac-arm64.zip",
304
- "mac12": "builds/firefox/%s/firefox-mac.zip",
305
- "mac12-arm64": "builds/firefox/%s/firefox-mac-arm64.zip",
306
- "mac13": "builds/firefox/%s/firefox-mac.zip",
307
- "mac13-arm64": "builds/firefox/%s/firefox-mac-arm64.zip",
308
- "mac14": "builds/firefox/%s/firefox-mac.zip",
309
- "mac14-arm64": "builds/firefox/%s/firefox-mac-arm64.zip",
310
- "mac15": "builds/firefox/%s/firefox-mac.zip",
311
- "mac15-arm64": "builds/firefox/%s/firefox-mac-arm64.zip",
312
- "win64": "builds/firefox/%s/firefox-win64.zip"
313
- },
314
- "firefox-beta": {
315
- "<unknown>": void 0,
316
- "ubuntu18.04-x64": void 0,
317
- "ubuntu20.04-x64": "builds/firefox-beta/%s/firefox-beta-ubuntu-20.04.zip",
318
- "ubuntu22.04-x64": "builds/firefox-beta/%s/firefox-beta-ubuntu-22.04.zip",
319
- "ubuntu24.04-x64": "builds/firefox-beta/%s/firefox-beta-ubuntu-24.04.zip",
320
- "ubuntu18.04-arm64": void 0,
321
- "ubuntu20.04-arm64": void 0,
322
- "ubuntu22.04-arm64": "builds/firefox-beta/%s/firefox-beta-ubuntu-22.04-arm64.zip",
323
- "ubuntu24.04-arm64": "builds/firefox-beta/%s/firefox-beta-ubuntu-24.04-arm64.zip",
324
- "debian11-x64": "builds/firefox-beta/%s/firefox-beta-debian-11.zip",
325
- "debian11-arm64": "builds/firefox-beta/%s/firefox-beta-debian-11-arm64.zip",
326
- "debian12-x64": "builds/firefox-beta/%s/firefox-beta-debian-12.zip",
327
- "debian12-arm64": "builds/firefox-beta/%s/firefox-beta-debian-12-arm64.zip",
328
- "debian13-x64": "builds/firefox-beta/%s/firefox-beta-debian-12.zip",
329
- "debian13-arm64": "builds/firefox-beta/%s/firefox-beta-debian-12-arm64.zip",
330
- "mac10.13": "builds/firefox-beta/%s/firefox-beta-mac.zip",
331
- "mac10.14": "builds/firefox-beta/%s/firefox-beta-mac.zip",
332
- "mac10.15": "builds/firefox-beta/%s/firefox-beta-mac.zip",
333
- "mac11": "builds/firefox-beta/%s/firefox-beta-mac.zip",
334
- "mac11-arm64": "builds/firefox-beta/%s/firefox-beta-mac-arm64.zip",
335
- "mac12": "builds/firefox-beta/%s/firefox-beta-mac.zip",
336
- "mac12-arm64": "builds/firefox-beta/%s/firefox-beta-mac-arm64.zip",
337
- "mac13": "builds/firefox-beta/%s/firefox-beta-mac.zip",
338
- "mac13-arm64": "builds/firefox-beta/%s/firefox-beta-mac-arm64.zip",
339
- "mac14": "builds/firefox-beta/%s/firefox-beta-mac.zip",
340
- "mac14-arm64": "builds/firefox-beta/%s/firefox-beta-mac-arm64.zip",
341
- "mac15": "builds/firefox-beta/%s/firefox-beta-mac.zip",
342
- "mac15-arm64": "builds/firefox-beta/%s/firefox-beta-mac-arm64.zip",
343
- "win64": "builds/firefox-beta/%s/firefox-beta-win64.zip"
344
- },
345
- "webkit": {
346
- "<unknown>": void 0,
347
- "ubuntu18.04-x64": void 0,
348
- "ubuntu20.04-x64": "builds/webkit/%s/webkit-ubuntu-20.04.zip",
349
- "ubuntu22.04-x64": "builds/webkit/%s/webkit-ubuntu-22.04.zip",
350
- "ubuntu24.04-x64": "builds/webkit/%s/webkit-ubuntu-24.04.zip",
351
- "ubuntu18.04-arm64": void 0,
352
- "ubuntu20.04-arm64": "builds/webkit/%s/webkit-ubuntu-20.04-arm64.zip",
353
- "ubuntu22.04-arm64": "builds/webkit/%s/webkit-ubuntu-22.04-arm64.zip",
354
- "ubuntu24.04-arm64": "builds/webkit/%s/webkit-ubuntu-24.04-arm64.zip",
355
- "debian11-x64": "builds/webkit/%s/webkit-debian-11.zip",
356
- "debian11-arm64": "builds/webkit/%s/webkit-debian-11-arm64.zip",
357
- "debian12-x64": "builds/webkit/%s/webkit-debian-12.zip",
358
- "debian12-arm64": "builds/webkit/%s/webkit-debian-12-arm64.zip",
359
- "debian13-x64": "builds/webkit/%s/webkit-debian-13.zip",
360
- "debian13-arm64": "builds/webkit/%s/webkit-debian-13-arm64.zip",
361
- "mac10.13": void 0,
362
- "mac10.14": void 0,
363
- "mac10.15": void 0,
364
- "mac11": void 0,
365
- "mac11-arm64": void 0,
366
- "mac12": void 0,
367
- "mac12-arm64": void 0,
368
- "mac13": void 0,
369
- "mac13-arm64": void 0,
370
- "mac14": "builds/webkit/%s/webkit-mac-14.zip",
371
- "mac14-arm64": "builds/webkit/%s/webkit-mac-14-arm64.zip",
372
- "mac15": "builds/webkit/%s/webkit-mac-15.zip",
373
- "mac15-arm64": "builds/webkit/%s/webkit-mac-15-arm64.zip",
374
- "win64": "builds/webkit/%s/webkit-win64.zip"
375
- },
376
- "ffmpeg": {
377
- "<unknown>": void 0,
378
- "ubuntu18.04-x64": void 0,
379
- "ubuntu20.04-x64": "builds/ffmpeg/%s/ffmpeg-linux.zip",
380
- "ubuntu22.04-x64": "builds/ffmpeg/%s/ffmpeg-linux.zip",
381
- "ubuntu24.04-x64": "builds/ffmpeg/%s/ffmpeg-linux.zip",
382
- "ubuntu18.04-arm64": void 0,
383
- "ubuntu20.04-arm64": "builds/ffmpeg/%s/ffmpeg-linux-arm64.zip",
384
- "ubuntu22.04-arm64": "builds/ffmpeg/%s/ffmpeg-linux-arm64.zip",
385
- "ubuntu24.04-arm64": "builds/ffmpeg/%s/ffmpeg-linux-arm64.zip",
386
- "debian11-x64": "builds/ffmpeg/%s/ffmpeg-linux.zip",
387
- "debian11-arm64": "builds/ffmpeg/%s/ffmpeg-linux-arm64.zip",
388
- "debian12-x64": "builds/ffmpeg/%s/ffmpeg-linux.zip",
389
- "debian12-arm64": "builds/ffmpeg/%s/ffmpeg-linux-arm64.zip",
390
- "debian13-x64": "builds/ffmpeg/%s/ffmpeg-linux.zip",
391
- "debian13-arm64": "builds/ffmpeg/%s/ffmpeg-linux-arm64.zip",
392
- "mac10.13": "builds/ffmpeg/%s/ffmpeg-mac.zip",
393
- "mac10.14": "builds/ffmpeg/%s/ffmpeg-mac.zip",
394
- "mac10.15": "builds/ffmpeg/%s/ffmpeg-mac.zip",
395
- "mac11": "builds/ffmpeg/%s/ffmpeg-mac.zip",
396
- "mac11-arm64": "builds/ffmpeg/%s/ffmpeg-mac-arm64.zip",
397
- "mac12": "builds/ffmpeg/%s/ffmpeg-mac.zip",
398
- "mac12-arm64": "builds/ffmpeg/%s/ffmpeg-mac-arm64.zip",
399
- "mac13": "builds/ffmpeg/%s/ffmpeg-mac.zip",
400
- "mac13-arm64": "builds/ffmpeg/%s/ffmpeg-mac-arm64.zip",
401
- "mac14": "builds/ffmpeg/%s/ffmpeg-mac.zip",
402
- "mac14-arm64": "builds/ffmpeg/%s/ffmpeg-mac-arm64.zip",
403
- "mac15": "builds/ffmpeg/%s/ffmpeg-mac.zip",
404
- "mac15-arm64": "builds/ffmpeg/%s/ffmpeg-mac-arm64.zip",
405
- "win64": "builds/ffmpeg/%s/ffmpeg-win64.zip"
406
- },
407
- "winldd": {
408
- "<unknown>": void 0,
409
- "ubuntu18.04-x64": void 0,
410
- "ubuntu20.04-x64": void 0,
411
- "ubuntu22.04-x64": void 0,
412
- "ubuntu24.04-x64": void 0,
413
- "ubuntu18.04-arm64": void 0,
414
- "ubuntu20.04-arm64": void 0,
415
- "ubuntu22.04-arm64": void 0,
416
- "ubuntu24.04-arm64": void 0,
417
- "debian11-x64": void 0,
418
- "debian11-arm64": void 0,
419
- "debian12-x64": void 0,
420
- "debian12-arm64": void 0,
421
- "debian13-x64": void 0,
422
- "debian13-arm64": void 0,
423
- "mac10.13": void 0,
424
- "mac10.14": void 0,
425
- "mac10.15": void 0,
426
- "mac11": void 0,
427
- "mac11-arm64": void 0,
428
- "mac12": void 0,
429
- "mac12-arm64": void 0,
430
- "mac13": void 0,
431
- "mac13-arm64": void 0,
432
- "mac14": void 0,
433
- "mac14-arm64": void 0,
434
- "mac15": void 0,
435
- "mac15-arm64": void 0,
436
- "win64": "builds/winldd/%s/winldd-win64.zip"
437
- },
438
- "android": {
439
- "<unknown>": "builds/android/%s/android.zip",
440
- "ubuntu18.04-x64": void 0,
441
- "ubuntu20.04-x64": "builds/android/%s/android.zip",
442
- "ubuntu22.04-x64": "builds/android/%s/android.zip",
443
- "ubuntu24.04-x64": "builds/android/%s/android.zip",
444
- "ubuntu18.04-arm64": void 0,
445
- "ubuntu20.04-arm64": "builds/android/%s/android.zip",
446
- "ubuntu22.04-arm64": "builds/android/%s/android.zip",
447
- "ubuntu24.04-arm64": "builds/android/%s/android.zip",
448
- "debian11-x64": "builds/android/%s/android.zip",
449
- "debian11-arm64": "builds/android/%s/android.zip",
450
- "debian12-x64": "builds/android/%s/android.zip",
451
- "debian12-arm64": "builds/android/%s/android.zip",
452
- "debian13-x64": "builds/android/%s/android.zip",
453
- "debian13-arm64": "builds/android/%s/android.zip",
454
- "mac10.13": "builds/android/%s/android.zip",
455
- "mac10.14": "builds/android/%s/android.zip",
456
- "mac10.15": "builds/android/%s/android.zip",
457
- "mac11": "builds/android/%s/android.zip",
458
- "mac11-arm64": "builds/android/%s/android.zip",
459
- "mac12": "builds/android/%s/android.zip",
460
- "mac12-arm64": "builds/android/%s/android.zip",
461
- "mac13": "builds/android/%s/android.zip",
462
- "mac13-arm64": "builds/android/%s/android.zip",
463
- "mac14": "builds/android/%s/android.zip",
464
- "mac14-arm64": "builds/android/%s/android.zip",
465
- "mac15": "builds/android/%s/android.zip",
466
- "mac15-arm64": "builds/android/%s/android.zip",
467
- "win64": "builds/android/%s/android.zip"
468
- }
469
- };
470
- const registryDirectory = (() => {
471
- let result;
472
- const envDefined = (0, import_utils.getFromENV)("PLAYWRIGHT_BROWSERS_PATH");
473
- if (envDefined === "0") {
474
- result = import_path.default.join(__dirname, "..", "..", "..", ".local-browsers");
475
- } else if (envDefined) {
476
- result = envDefined;
477
- } else {
478
- let cacheDirectory;
479
- if (process.platform === "linux")
480
- cacheDirectory = process.env.XDG_CACHE_HOME || import_path.default.join(import_os.default.homedir(), ".cache");
481
- else if (process.platform === "darwin")
482
- cacheDirectory = import_path.default.join(import_os.default.homedir(), "Library", "Caches");
483
- else if (process.platform === "win32")
484
- cacheDirectory = process.env.LOCALAPPDATA || import_path.default.join(import_os.default.homedir(), "AppData", "Local");
485
- else
486
- throw new Error("Unsupported platform: " + process.platform);
487
- result = import_path.default.join(cacheDirectory, "ms-playwright");
488
- }
489
- if (!import_path.default.isAbsolute(result)) {
490
- result = import_path.default.resolve((0, import_utils.getFromENV)("INIT_CWD") || process.cwd(), result);
491
- }
492
- return result;
493
- })();
494
- function isBrowserDirectory(browserDirectory) {
495
- const baseName = import_path.default.basename(browserDirectory);
496
- for (const browserName of allDownloadableDirectoriesThatEverExisted) {
497
- if (baseName.startsWith(browserName.replace(/-/g, "_") + "-"))
498
- return true;
499
- }
500
- return false;
501
- }
502
- function readDescriptors(browsersJSON) {
503
- return browsersJSON["browsers"].map((obj) => {
504
- const name = obj.name;
505
- const revisionOverride = (obj.revisionOverrides || {})[import_hostPlatform.hostPlatform];
506
- const revision = revisionOverride || obj.revision;
507
- const browserDirectoryPrefix = revisionOverride ? `${name}_${import_hostPlatform.hostPlatform}_special` : `${name}`;
508
- const descriptor = {
509
- name,
510
- revision,
511
- hasRevisionOverride: !!revisionOverride,
512
- // We only put browser version for the supported operating systems.
513
- browserVersion: revisionOverride ? void 0 : obj.browserVersion,
514
- title: obj["title"],
515
- installByDefault: !!obj.installByDefault,
516
- // Method `isBrowserDirectory` determines directory to be browser iff
517
- // it starts with some browser name followed by '-'. Some browser names
518
- // are prefixes of others, e.g. 'webkit' is a prefix of `webkit-technology-preview`.
519
- // To avoid older registries erroneously removing 'webkit-technology-preview', we have to
520
- // ensure that browser folders to never include dashes inside.
521
- dir: import_path.default.join(registryDirectory, browserDirectoryPrefix.replace(/-/g, "_") + "-" + revision)
522
- };
523
- return descriptor;
524
- });
525
- }
526
- const allDownloadableDirectoriesThatEverExisted = ["android", "chromium", "firefox", "webkit", "ffmpeg", "firefox-beta", "chromium-tip-of-tree", "chromium-headless-shell", "chromium-tip-of-tree-headless-shell", "winldd"];
527
- const chromiumAliases = ["bidi-chromium", "chrome-for-testing"];
528
- class Registry {
529
- constructor(browsersJSON) {
530
- const descriptors = readDescriptors(browsersJSON);
531
- const findExecutablePath = (dir, name) => {
532
- const tokens = EXECUTABLE_PATHS[name][import_hostPlatform.shortPlatform];
533
- return tokens ? import_path.default.join(dir, ...tokens) : void 0;
534
- };
535
- const executablePathOrDie = (name, e, installByDefault, sdkLanguage) => {
536
- if (!e)
537
- throw new Error(`${name} is not supported on ${import_hostPlatform.hostPlatform}`);
538
- const installCommand = buildPlaywrightCLICommand(sdkLanguage, `install${installByDefault ? "" : " " + name}`);
539
- if (!(0, import_fileUtils.canAccessFile)(e)) {
540
- const currentDockerVersion = (0, import_dependencies.readDockerVersionSync)();
541
- const preferredDockerVersion = currentDockerVersion ? (0, import_dependencies.dockerVersion)(currentDockerVersion.dockerImageNameTemplate) : null;
542
- const isOutdatedDockerImage = currentDockerVersion && preferredDockerVersion && currentDockerVersion.dockerImageName !== preferredDockerVersion.dockerImageName;
543
- const prettyMessage = isOutdatedDockerImage ? [
544
- `Looks like ${sdkLanguage === "javascript" ? "Playwright Test or " : ""}Playwright was just updated to ${preferredDockerVersion.driverVersion}.`,
545
- `Please update docker image as well.`,
546
- `- current: ${currentDockerVersion.dockerImageName}`,
547
- `- required: ${preferredDockerVersion.dockerImageName}`,
548
- ``,
549
- `<3 Playwright Team`
550
- ].join("\n") : [
551
- `Looks like ${sdkLanguage === "javascript" ? "Playwright Test or " : ""}Playwright was just installed or updated.`,
552
- `Please run the following command to download new browser${installByDefault ? "s" : ""}:`,
553
- ``,
554
- ` ${installCommand}`,
555
- ``,
556
- `<3 Playwright Team`
557
- ].join("\n");
558
- throw new Error(`Executable doesn't exist at ${e}
559
- ${(0, import_ascii.wrapInASCIIBox)(prettyMessage, 1)}`);
560
- }
561
- return e;
562
- };
563
- this._executables = [];
564
- const chromium = descriptors.find((d) => d.name === "chromium");
565
- const chromiumExecutable = findExecutablePath(chromium.dir, "chromium");
566
- this._executables.push({
567
- name: "chromium",
568
- browserName: "chromium",
569
- directory: chromium.dir,
570
- executablePath: () => chromiumExecutable,
571
- executablePathOrDie: (sdkLanguage) => executablePathOrDie("chromium", chromiumExecutable, chromium.installByDefault, sdkLanguage),
572
- installType: chromium.installByDefault ? "download-by-default" : "download-on-demand",
573
- _validateHostRequirements: (sdkLanguage) => this._validateHostRequirements(sdkLanguage, chromium.dir, ["chrome-linux"], [], ["chrome-win"]),
574
- downloadURLs: this._downloadURLs(chromium),
575
- title: chromium.title,
576
- revision: chromium.revision,
577
- browserVersion: chromium.browserVersion,
578
- _install: (force) => this._downloadExecutable(chromium, force, chromiumExecutable),
579
- _dependencyGroup: "chromium",
580
- _isHermeticInstallation: true
581
- });
582
- const chromiumHeadlessShell = descriptors.find((d) => d.name === "chromium-headless-shell");
583
- const chromiumHeadlessShellExecutable = findExecutablePath(chromiumHeadlessShell.dir, "chromium-headless-shell");
584
- this._executables.push({
585
- name: "chromium-headless-shell",
586
- browserName: "chromium",
587
- directory: chromiumHeadlessShell.dir,
588
- executablePath: () => chromiumHeadlessShellExecutable,
589
- executablePathOrDie: (sdkLanguage) => executablePathOrDie("chromium", chromiumHeadlessShellExecutable, chromiumHeadlessShell.installByDefault, sdkLanguage),
590
- installType: chromiumHeadlessShell.installByDefault ? "download-by-default" : "download-on-demand",
591
- _validateHostRequirements: (sdkLanguage) => this._validateHostRequirements(sdkLanguage, chromiumHeadlessShell.dir, ["chrome-linux"], [], ["chrome-win"]),
592
- downloadURLs: this._downloadURLs(chromiumHeadlessShell),
593
- title: chromiumHeadlessShell.title,
594
- revision: chromiumHeadlessShell.revision,
595
- browserVersion: chromiumHeadlessShell.browserVersion,
596
- _install: (force) => this._downloadExecutable(chromiumHeadlessShell, force, chromiumHeadlessShellExecutable),
597
- _dependencyGroup: "chromium",
598
- _isHermeticInstallation: true
599
- });
600
- const chromiumTipOfTreeHeadlessShell = descriptors.find((d) => d.name === "chromium-tip-of-tree-headless-shell");
601
- const chromiumTipOfTreeHeadlessShellExecutable = findExecutablePath(chromiumTipOfTreeHeadlessShell.dir, "chromium-tip-of-tree-headless-shell");
602
- this._executables.push({
603
- name: "chromium-tip-of-tree-headless-shell",
604
- browserName: "chromium",
605
- directory: chromiumTipOfTreeHeadlessShell.dir,
606
- executablePath: () => chromiumTipOfTreeHeadlessShellExecutable,
607
- executablePathOrDie: (sdkLanguage) => executablePathOrDie("chromium", chromiumTipOfTreeHeadlessShellExecutable, chromiumTipOfTreeHeadlessShell.installByDefault, sdkLanguage),
608
- installType: chromiumTipOfTreeHeadlessShell.installByDefault ? "download-by-default" : "download-on-demand",
609
- _validateHostRequirements: (sdkLanguage) => this._validateHostRequirements(sdkLanguage, chromiumTipOfTreeHeadlessShell.dir, ["chrome-linux"], [], ["chrome-win"]),
610
- downloadURLs: this._downloadURLs(chromiumTipOfTreeHeadlessShell),
611
- title: chromiumTipOfTreeHeadlessShell.title,
612
- revision: chromiumTipOfTreeHeadlessShell.revision,
613
- browserVersion: chromiumTipOfTreeHeadlessShell.browserVersion,
614
- _install: (force) => this._downloadExecutable(chromiumTipOfTreeHeadlessShell, force, chromiumTipOfTreeHeadlessShellExecutable),
615
- _dependencyGroup: "chromium",
616
- _isHermeticInstallation: true
617
- });
618
- const chromiumTipOfTree = descriptors.find((d) => d.name === "chromium-tip-of-tree");
619
- const chromiumTipOfTreeExecutable = findExecutablePath(chromiumTipOfTree.dir, "chromium-tip-of-tree");
620
- this._executables.push({
621
- name: "chromium-tip-of-tree",
622
- browserName: "chromium",
623
- directory: chromiumTipOfTree.dir,
624
- executablePath: () => chromiumTipOfTreeExecutable,
625
- executablePathOrDie: (sdkLanguage) => executablePathOrDie("chromium-tip-of-tree", chromiumTipOfTreeExecutable, chromiumTipOfTree.installByDefault, sdkLanguage),
626
- installType: chromiumTipOfTree.installByDefault ? "download-by-default" : "download-on-demand",
627
- _validateHostRequirements: (sdkLanguage) => this._validateHostRequirements(sdkLanguage, chromiumTipOfTree.dir, ["chrome-linux"], [], ["chrome-win"]),
628
- downloadURLs: this._downloadURLs(chromiumTipOfTree),
629
- title: chromiumTipOfTree.title,
630
- revision: chromiumTipOfTree.revision,
631
- browserVersion: chromiumTipOfTree.browserVersion,
632
- _install: (force) => this._downloadExecutable(chromiumTipOfTree, force, chromiumTipOfTreeExecutable),
633
- _dependencyGroup: "chromium",
634
- _isHermeticInstallation: true
635
- });
636
- this._executables.push(this._createChromiumChannel("chrome", {
637
- "linux": "/opt/google/chrome/chrome",
638
- "darwin": "/Applications/Google Chrome.app/Contents/MacOS/Google Chrome",
639
- "win32": `\\Google\\Chrome\\Application\\chrome.exe`
640
- }, () => this._installChromiumChannel("chrome", {
641
- "linux": "reinstall_chrome_stable_linux.sh",
642
- "darwin": "reinstall_chrome_stable_mac.sh",
643
- "win32": "reinstall_chrome_stable_win.ps1"
644
- })));
645
- this._executables.push(this._createChromiumChannel("chrome-beta", {
646
- "linux": "/opt/google/chrome-beta/chrome",
647
- "darwin": "/Applications/Google Chrome Beta.app/Contents/MacOS/Google Chrome Beta",
648
- "win32": `\\Google\\Chrome Beta\\Application\\chrome.exe`
649
- }, () => this._installChromiumChannel("chrome-beta", {
650
- "linux": "reinstall_chrome_beta_linux.sh",
651
- "darwin": "reinstall_chrome_beta_mac.sh",
652
- "win32": "reinstall_chrome_beta_win.ps1"
653
- })));
654
- this._executables.push(this._createChromiumChannel("chrome-dev", {
655
- "linux": "/opt/google/chrome-unstable/chrome",
656
- "darwin": "/Applications/Google Chrome Dev.app/Contents/MacOS/Google Chrome Dev",
657
- "win32": `\\Google\\Chrome Dev\\Application\\chrome.exe`
658
- }));
659
- this._executables.push(this._createChromiumChannel("chrome-canary", {
660
- "linux": "/opt/google/chrome-canary/chrome",
661
- "darwin": "/Applications/Google Chrome Canary.app/Contents/MacOS/Google Chrome Canary",
662
- "win32": `\\Google\\Chrome SxS\\Application\\chrome.exe`
663
- }));
664
- this._executables.push(this._createChromiumChannel("msedge", {
665
- "linux": "/opt/microsoft/msedge/msedge",
666
- "darwin": "/Applications/Microsoft Edge.app/Contents/MacOS/Microsoft Edge",
667
- "win32": `\\Microsoft\\Edge\\Application\\msedge.exe`
668
- }, () => this._installMSEdgeChannel("msedge", {
669
- "linux": "reinstall_msedge_stable_linux.sh",
670
- "darwin": "reinstall_msedge_stable_mac.sh",
671
- "win32": "reinstall_msedge_stable_win.ps1"
672
- })));
673
- this._executables.push(this._createChromiumChannel("msedge-beta", {
674
- "linux": "/opt/microsoft/msedge-beta/msedge",
675
- "darwin": "/Applications/Microsoft Edge Beta.app/Contents/MacOS/Microsoft Edge Beta",
676
- "win32": `\\Microsoft\\Edge Beta\\Application\\msedge.exe`
677
- }, () => this._installMSEdgeChannel("msedge-beta", {
678
- "darwin": "reinstall_msedge_beta_mac.sh",
679
- "linux": "reinstall_msedge_beta_linux.sh",
680
- "win32": "reinstall_msedge_beta_win.ps1"
681
- })));
682
- this._executables.push(this._createChromiumChannel("msedge-dev", {
683
- "linux": "/opt/microsoft/msedge-dev/msedge",
684
- "darwin": "/Applications/Microsoft Edge Dev.app/Contents/MacOS/Microsoft Edge Dev",
685
- "win32": `\\Microsoft\\Edge Dev\\Application\\msedge.exe`
686
- }, () => this._installMSEdgeChannel("msedge-dev", {
687
- "darwin": "reinstall_msedge_dev_mac.sh",
688
- "linux": "reinstall_msedge_dev_linux.sh",
689
- "win32": "reinstall_msedge_dev_win.ps1"
690
- })));
691
- this._executables.push(this._createChromiumChannel("msedge-canary", {
692
- "linux": "",
693
- "darwin": "/Applications/Microsoft Edge Canary.app/Contents/MacOS/Microsoft Edge Canary",
694
- "win32": `\\Microsoft\\Edge SxS\\Application\\msedge.exe`
695
- }));
696
- this._executables.push(this._createBidiFirefoxChannel("moz-firefox", {
697
- "linux": "/snap/bin/firefox",
698
- "darwin": "/Applications/Firefox.app/Contents/MacOS/firefox",
699
- "win32": "\\Mozilla Firefox\\firefox.exe"
700
- }));
701
- this._executables.push(this._createBidiFirefoxChannel("moz-firefox-beta", {
702
- "linux": "/opt/firefox-beta/firefox",
703
- "darwin": "/Applications/Firefox.app/Contents/MacOS/firefox",
704
- "win32": "\\Mozilla Firefox\\firefox.exe"
705
- }));
706
- this._executables.push(this._createBidiFirefoxChannel("moz-firefox-nightly", {
707
- "linux": "/opt/firefox-nightly/firefox",
708
- "darwin": "/Applications/Firefox Nightly.app/Contents/MacOS/firefox",
709
- "win32": "\\Mozilla Firefox\\firefox.exe"
710
- }));
711
- this._executables.push(this._createBidiChromiumChannel("bidi-chrome-stable", {
712
- "linux": "/opt/google/chrome/chrome",
713
- "darwin": "/Applications/Google Chrome.app/Contents/MacOS/Google Chrome",
714
- "win32": `\\Google\\Chrome\\Application\\chrome.exe`
715
- }));
716
- this._executables.push(this._createBidiChromiumChannel("bidi-chrome-canary", {
717
- "linux": "/opt/google/chrome-canary/chrome",
718
- "darwin": "/Applications/Google Chrome Canary.app/Contents/MacOS/Google Chrome Canary",
719
- "win32": `\\Google\\Chrome SxS\\Application\\chrome.exe`
720
- }));
721
- const firefox = descriptors.find((d) => d.name === "firefox");
722
- const firefoxExecutable = findExecutablePath(firefox.dir, "firefox");
723
- this._executables.push({
724
- name: "firefox",
725
- browserName: "firefox",
726
- directory: firefox.dir,
727
- executablePath: () => firefoxExecutable,
728
- executablePathOrDie: (sdkLanguage) => executablePathOrDie("firefox", firefoxExecutable, firefox.installByDefault, sdkLanguage),
729
- installType: firefox.installByDefault ? "download-by-default" : "download-on-demand",
730
- _validateHostRequirements: (sdkLanguage) => this._validateHostRequirements(sdkLanguage, firefox.dir, ["firefox"], [], ["firefox"]),
731
- downloadURLs: this._downloadURLs(firefox),
732
- title: firefox.title,
733
- revision: firefox.revision,
734
- browserVersion: firefox.browserVersion,
735
- _install: (force) => this._downloadExecutable(firefox, force, firefoxExecutable),
736
- _dependencyGroup: "firefox",
737
- _isHermeticInstallation: true
738
- });
739
- const firefoxBeta = descriptors.find((d) => d.name === "firefox-beta");
740
- const firefoxBetaExecutable = findExecutablePath(firefoxBeta.dir, "firefox");
741
- this._executables.push({
742
- name: "firefox-beta",
743
- browserName: "firefox",
744
- directory: firefoxBeta.dir,
745
- executablePath: () => firefoxBetaExecutable,
746
- executablePathOrDie: (sdkLanguage) => executablePathOrDie("firefox-beta", firefoxBetaExecutable, firefoxBeta.installByDefault, sdkLanguage),
747
- installType: firefoxBeta.installByDefault ? "download-by-default" : "download-on-demand",
748
- _validateHostRequirements: (sdkLanguage) => this._validateHostRequirements(sdkLanguage, firefoxBeta.dir, ["firefox"], [], ["firefox"]),
749
- downloadURLs: this._downloadURLs(firefoxBeta),
750
- title: firefoxBeta.title,
751
- revision: firefoxBeta.revision,
752
- browserVersion: firefoxBeta.browserVersion,
753
- _install: (force) => this._downloadExecutable(firefoxBeta, force, firefoxBetaExecutable),
754
- _dependencyGroup: "firefox",
755
- _isHermeticInstallation: true
756
- });
757
- const webkit = descriptors.find((d) => d.name === "webkit");
758
- const webkitExecutable = findExecutablePath(webkit.dir, "webkit");
759
- const webkitLinuxLddDirectories = [
760
- import_path.default.join("minibrowser-gtk"),
761
- import_path.default.join("minibrowser-gtk", "bin"),
762
- import_path.default.join("minibrowser-gtk", "lib"),
763
- import_path.default.join("minibrowser-gtk", "sys", "lib"),
764
- import_path.default.join("minibrowser-wpe"),
765
- import_path.default.join("minibrowser-wpe", "bin"),
766
- import_path.default.join("minibrowser-wpe", "lib"),
767
- import_path.default.join("minibrowser-wpe", "sys", "lib")
768
- ];
769
- this._executables.push({
770
- name: "webkit",
771
- browserName: "webkit",
772
- directory: webkit.dir,
773
- executablePath: () => webkitExecutable,
774
- executablePathOrDie: (sdkLanguage) => executablePathOrDie("webkit", webkitExecutable, webkit.installByDefault, sdkLanguage),
775
- installType: webkit.installByDefault ? "download-by-default" : "download-on-demand",
776
- _validateHostRequirements: (sdkLanguage) => this._validateHostRequirements(sdkLanguage, webkit.dir, webkitLinuxLddDirectories, ["libGLESv2.so.2", "libx264.so"], [""]),
777
- downloadURLs: this._downloadURLs(webkit),
778
- title: webkit.title,
779
- revision: webkit.revision,
780
- browserVersion: webkit.browserVersion,
781
- _install: (force) => this._downloadExecutable(webkit, force, webkitExecutable),
782
- _dependencyGroup: "webkit",
783
- _isHermeticInstallation: true
784
- });
785
- this._executables.push({
786
- name: "webkit-wsl",
787
- browserName: "webkit",
788
- directory: webkit.dir,
789
- executablePath: () => webkitExecutable,
790
- executablePathOrDie: (sdkLanguage) => executablePathOrDie("webkit", webkitExecutable, webkit.installByDefault, sdkLanguage),
791
- installType: "download-on-demand",
792
- title: "Webkit in WSL",
793
- _validateHostRequirements: (sdkLanguage) => Promise.resolve(),
794
- _isHermeticInstallation: true,
795
- _install: async () => {
796
- if (process.platform !== "win32")
797
- throw new Error(`WebKit via WSL is only supported on Windows`);
798
- const script = import_path.default.join(BIN_PATH, "install_webkit_wsl.ps1");
799
- const { code } = await (0, import_spawnAsync.spawnAsync)("powershell.exe", [
800
- "-ExecutionPolicy",
801
- "Bypass",
802
- "-File",
803
- script
804
- ], {
805
- stdio: "inherit"
806
- });
807
- if (code !== 0)
808
- throw new Error(`Failed to install WebKit via WSL`);
809
- }
810
- });
811
- const ffmpeg = descriptors.find((d) => d.name === "ffmpeg");
812
- const ffmpegExecutable = findExecutablePath(ffmpeg.dir, "ffmpeg");
813
- this._executables.push({
814
- name: "ffmpeg",
815
- browserName: void 0,
816
- directory: ffmpeg.dir,
817
- executablePath: () => ffmpegExecutable,
818
- executablePathOrDie: (sdkLanguage) => executablePathOrDie("ffmpeg", ffmpegExecutable, ffmpeg.installByDefault, sdkLanguage),
819
- installType: ffmpeg.installByDefault ? "download-by-default" : "download-on-demand",
820
- _validateHostRequirements: () => Promise.resolve(),
821
- downloadURLs: this._downloadURLs(ffmpeg),
822
- title: ffmpeg.title,
823
- revision: ffmpeg.revision,
824
- _install: (force) => this._downloadExecutable(ffmpeg, force, ffmpegExecutable),
825
- _dependencyGroup: "tools",
826
- _isHermeticInstallation: true
827
- });
828
- const winldd = descriptors.find((d) => d.name === "winldd");
829
- const winlddExecutable = findExecutablePath(winldd.dir, "winldd");
830
- this._executables.push({
831
- name: "winldd",
832
- browserName: void 0,
833
- directory: winldd.dir,
834
- executablePath: () => winlddExecutable,
835
- executablePathOrDie: (sdkLanguage) => executablePathOrDie("winldd", winlddExecutable, winldd.installByDefault, sdkLanguage),
836
- installType: process.platform === "win32" ? "download-by-default" : "none",
837
- _validateHostRequirements: () => Promise.resolve(),
838
- downloadURLs: this._downloadURLs(winldd),
839
- title: winldd.title,
840
- revision: winldd.revision,
841
- _install: (force) => this._downloadExecutable(winldd, force, winlddExecutable),
842
- _dependencyGroup: "tools",
843
- _isHermeticInstallation: true
844
- });
845
- const android = descriptors.find((d) => d.name === "android");
846
- this._executables.push({
847
- name: "android",
848
- browserName: void 0,
849
- directory: android.dir,
850
- executablePath: () => void 0,
851
- executablePathOrDie: () => "",
852
- installType: "download-on-demand",
853
- _validateHostRequirements: () => Promise.resolve(),
854
- downloadURLs: this._downloadURLs(android),
855
- title: android.title,
856
- revision: android.revision,
857
- _install: (force) => this._downloadExecutable(android, force),
858
- _dependencyGroup: "tools",
859
- _isHermeticInstallation: true
860
- });
861
- }
862
- _createChromiumChannel(name, lookAt, install) {
863
- const executablePath = (sdkLanguage, shouldThrow) => {
864
- const suffix = lookAt[process.platform];
865
- if (!suffix) {
866
- if (shouldThrow)
867
- throw new Error(`Chromium distribution '${name}' is not supported on ${process.platform}`);
868
- return void 0;
869
- }
870
- const prefixes = process.platform === "win32" ? [
871
- process.env.LOCALAPPDATA,
872
- process.env.PROGRAMFILES,
873
- process.env["PROGRAMFILES(X86)"],
874
- // In some cases there is no PROGRAMFILES/(86) env var set but HOMEDRIVE is set.
875
- process.env.HOMEDRIVE + "\\Program Files",
876
- process.env.HOMEDRIVE + "\\Program Files (x86)"
877
- ].filter(Boolean) : [""];
878
- for (const prefix of prefixes) {
879
- const executablePath2 = import_path.default.join(prefix, suffix);
880
- if ((0, import_fileUtils.canAccessFile)(executablePath2))
881
- return executablePath2;
882
- }
883
- if (!shouldThrow)
884
- return void 0;
885
- const location = prefixes.length ? ` at ${import_path.default.join(prefixes[0], suffix)}` : ``;
886
- const installation = install ? `
887
- Run "${buildPlaywrightCLICommand(sdkLanguage, "install " + name)}"` : "";
888
- throw new Error(`Chromium distribution '${name}' is not found${location}${installation}`);
889
- };
890
- return {
891
- name,
892
- browserName: "chromium",
893
- directory: void 0,
894
- executablePath: (sdkLanguage) => executablePath(sdkLanguage, false),
895
- executablePathOrDie: (sdkLanguage) => executablePath(sdkLanguage, true),
896
- installType: install ? "install-script" : "none",
897
- _validateHostRequirements: () => Promise.resolve(),
898
- _isHermeticInstallation: false,
899
- _install: install
900
- };
901
- }
902
- _createBidiFirefoxChannel(name, lookAt, install) {
903
- const executablePath = (sdkLanguage, shouldThrow) => {
904
- const suffix = lookAt[process.platform];
905
- if (!suffix) {
906
- if (shouldThrow)
907
- throw new Error(`Firefox distribution '${name}' is not supported on ${process.platform}`);
908
- return void 0;
909
- }
910
- const prefixes = process.platform === "win32" ? [
911
- process.env.LOCALAPPDATA,
912
- process.env.PROGRAMFILES,
913
- process.env["PROGRAMFILES(X86)"],
914
- // In some cases there is no PROGRAMFILES/(86) env var set but HOMEDRIVE is set.
915
- process.env.HOMEDRIVE + "\\Program Files",
916
- process.env.HOMEDRIVE + "\\Program Files (x86)"
917
- ].filter(Boolean) : [""];
918
- for (const prefix of prefixes) {
919
- const executablePath2 = import_path.default.join(prefix, suffix);
920
- if ((0, import_fileUtils.canAccessFile)(executablePath2))
921
- return executablePath2;
922
- }
923
- if (shouldThrow)
924
- throw new Error(`Cannot find Firefox installation for channel '${name}' at the standard system paths. ${`Tried paths:
925
- ${prefixes.map((p) => import_path.default.join(p, suffix)).join("\n ")}`}`);
926
- return void 0;
927
- };
928
- return {
929
- name,
930
- browserName: "firefox",
931
- directory: void 0,
932
- executablePath: (sdkLanguage) => executablePath(sdkLanguage, false),
933
- executablePathOrDie: (sdkLanguage) => executablePath(sdkLanguage, true),
934
- installType: "none",
935
- _validateHostRequirements: () => Promise.resolve(),
936
- _isHermeticInstallation: true,
937
- _install: install
938
- };
939
- }
940
- _createBidiChromiumChannel(name, lookAt) {
941
- const executablePath = (sdkLanguage, shouldThrow) => {
942
- const suffix = lookAt[process.platform];
943
- if (!suffix) {
944
- if (shouldThrow)
945
- throw new Error(`Chromium distribution '${name}' is not supported on ${process.platform}`);
946
- return void 0;
947
- }
948
- const prefixes = process.platform === "win32" ? [
949
- process.env.LOCALAPPDATA,
950
- process.env.PROGRAMFILES,
951
- process.env["PROGRAMFILES(X86)"],
952
- // In some cases there is no PROGRAMFILES/(86) env var set but HOMEDRIVE is set.
953
- process.env.HOMEDRIVE + "\\Program Files",
954
- process.env.HOMEDRIVE + "\\Program Files (x86)"
955
- ].filter(Boolean) : [""];
956
- for (const prefix of prefixes) {
957
- const executablePath2 = import_path.default.join(prefix, suffix);
958
- if ((0, import_fileUtils.canAccessFile)(executablePath2))
959
- return executablePath2;
960
- }
961
- if (!shouldThrow)
962
- return void 0;
963
- const location = prefixes.length ? ` at ${import_path.default.join(prefixes[0], suffix)}` : ``;
964
- throw new Error(`Chromium distribution '${name}' is not found${location}`);
965
- };
966
- return {
967
- name,
968
- browserName: "chromium",
969
- directory: void 0,
970
- executablePath: (sdkLanguage) => executablePath(sdkLanguage, false),
971
- executablePathOrDie: (sdkLanguage) => executablePath(sdkLanguage, true),
972
- installType: "none",
973
- _validateHostRequirements: () => Promise.resolve(),
974
- _isHermeticInstallation: false
975
- };
976
- }
977
- executables() {
978
- return this._executables;
979
- }
980
- findExecutable(name) {
981
- return this._executables.find((b) => b.name === name);
982
- }
983
- defaultExecutables() {
984
- return this._executables.filter((e) => e.installType === "download-by-default");
985
- }
986
- _dedupe(executables) {
987
- return Array.from(new Set(executables));
988
- }
989
- async _validateHostRequirements(sdkLanguage, browserDirectory, linuxLddDirectories, dlOpenLibraries, windowsExeAndDllDirectories) {
990
- if (import_os.default.platform() === "linux")
991
- return await (0, import_dependencies2.validateDependenciesLinux)(sdkLanguage, linuxLddDirectories.map((d) => import_path.default.join(browserDirectory, d)), dlOpenLibraries);
992
- if (import_os.default.platform() === "win32" && import_os.default.arch() === "x64")
993
- return await (0, import_dependencies2.validateDependenciesWindows)(sdkLanguage, windowsExeAndDllDirectories.map((d) => import_path.default.join(browserDirectory, d)));
994
- }
995
- async installDeps(executablesToInstallDeps, dryRun) {
996
- const executables = this._dedupe(executablesToInstallDeps);
997
- const targets = /* @__PURE__ */ new Set();
998
- for (const executable of executables) {
999
- if (executable._dependencyGroup)
1000
- targets.add(executable._dependencyGroup);
1001
- }
1002
- targets.add("tools");
1003
- if (import_os.default.platform() === "win32")
1004
- return await (0, import_dependencies2.installDependenciesWindows)(targets, dryRun);
1005
- if (import_os.default.platform() === "linux")
1006
- return await (0, import_dependencies2.installDependenciesLinux)(targets, dryRun);
1007
- }
1008
- async install(executablesToInstall, options) {
1009
- const executables = this._dedupe(executablesToInstall);
1010
- await import_fs.default.promises.mkdir(registryDirectory, { recursive: true });
1011
- const lockfilePath = import_path.default.join(registryDirectory, "__dirlock");
1012
- const linksDir = import_path.default.join(registryDirectory, ".links");
1013
- let releaseLock;
1014
- try {
1015
- releaseLock = await import_utilsBundle.lockfile.lock(registryDirectory, {
1016
- retries: {
1017
- // Retry 20 times during 10 minutes with
1018
- // exponential back-off.
1019
- // See documentation at: https://www.npmjs.com/package/retry#retrytimeoutsoptions
1020
- retries: 20,
1021
- factor: 1.27579
1022
- },
1023
- onCompromised: (err) => {
1024
- throw new Error(`${err.message} Path: ${lockfilePath}`);
1025
- },
1026
- lockfilePath
1027
- });
1028
- await import_fs.default.promises.mkdir(linksDir, { recursive: true });
1029
- await import_fs.default.promises.writeFile(import_path.default.join(linksDir, (0, import_utils.calculateSha1)(PACKAGE_PATH)), PACKAGE_PATH);
1030
- if (!(0, import_utils.getAsBooleanFromENV)("PLAYWRIGHT_SKIP_BROWSER_GC"))
1031
- await this._validateInstallationCache(linksDir);
1032
- for (const executable of executables) {
1033
- if (!executable._install)
1034
- throw new Error(`ERROR: Playwright does not support installing ${executable.name}`);
1035
- const { embedderName } = (0, import_userAgent.getEmbedderName)();
1036
- if (!(0, import_utils.getAsBooleanFromENV)("CI") && !executable._isHermeticInstallation && !options?.force && executable.executablePath(embedderName)) {
1037
- const command = buildPlaywrightCLICommand(embedderName, "install --force " + executable.name);
1038
- process.stderr.write("\n" + (0, import_ascii.wrapInASCIIBox)([
1039
- `ATTENTION: "${executable.name}" is already installed on the system!`,
1040
- ``,
1041
- `"${executable.name}" installation is not hermetic; installing newer version`,
1042
- `requires *removal* of a current installation first.`,
1043
- ``,
1044
- `To *uninstall* current version and re-install latest "${executable.name}":`,
1045
- ``,
1046
- `- Close all running instances of "${executable.name}", if any`,
1047
- `- Use "--force" to install browser:`,
1048
- ``,
1049
- ` ${command}`,
1050
- ``,
1051
- `<3 Playwright Team`
1052
- ].join("\n"), 1) + "\n\n");
1053
- return;
1054
- }
1055
- await executable._install(!!options?.force);
1056
- }
1057
- } catch (e) {
1058
- if (e.code === "ELOCKED") {
1059
- const rmCommand = process.platform === "win32" ? "rm -R" : "rm -rf";
1060
- throw new Error("\n" + (0, import_ascii.wrapInASCIIBox)([
1061
- `An active lockfile is found at:`,
1062
- ``,
1063
- ` ${lockfilePath}`,
1064
- ``,
1065
- `Either:`,
1066
- `- wait a few minutes if other Playwright is installing browsers in parallel`,
1067
- `- remove lock manually with:`,
1068
- ``,
1069
- ` ${rmCommand} ${lockfilePath}`,
1070
- ``,
1071
- `<3 Playwright Team`
1072
- ].join("\n"), 1));
1073
- } else {
1074
- throw e;
1075
- }
1076
- } finally {
1077
- if (releaseLock)
1078
- await releaseLock();
1079
- }
1080
- }
1081
- async uninstall(all) {
1082
- const linksDir = import_path.default.join(registryDirectory, ".links");
1083
- if (all) {
1084
- const links = await import_fs.default.promises.readdir(linksDir).catch(() => []);
1085
- for (const link of links)
1086
- await import_fs.default.promises.unlink(import_path.default.join(linksDir, link));
1087
- } else {
1088
- await import_fs.default.promises.unlink(import_path.default.join(linksDir, (0, import_utils.calculateSha1)(PACKAGE_PATH))).catch(() => {
1089
- });
1090
- }
1091
- await this._validateInstallationCache(linksDir);
1092
- return {
1093
- numberOfBrowsersLeft: (await import_fs.default.promises.readdir(registryDirectory).catch(() => [])).filter((browserDirectory) => isBrowserDirectory(browserDirectory)).length
1094
- };
1095
- }
1096
- async validateHostRequirementsForExecutablesIfNeeded(executables, sdkLanguage) {
1097
- if ((0, import_utils.getAsBooleanFromENV)("PLAYWRIGHT_SKIP_VALIDATE_HOST_REQUIREMENTS")) {
1098
- process.stderr.write("Skipping host requirements validation logic because `PLAYWRIGHT_SKIP_VALIDATE_HOST_REQUIREMENTS` env variable is set.\n");
1099
- return;
1100
- }
1101
- for (const executable of executables)
1102
- await this._validateHostRequirementsForExecutableIfNeeded(executable, sdkLanguage);
1103
- }
1104
- async _validateHostRequirementsForExecutableIfNeeded(executable, sdkLanguage) {
1105
- const kMaximumReValidationPeriod = 30 * 24 * 60 * 60 * 1e3;
1106
- if (!executable.directory)
1107
- return;
1108
- const markerFile = import_path.default.join(executable.directory, "DEPENDENCIES_VALIDATED");
1109
- if (await import_fs.default.promises.stat(markerFile).then((stat) => Date.now() - stat.mtime.getTime() < kMaximumReValidationPeriod).catch(() => false))
1110
- return;
1111
- import_debugLogger.debugLogger.log("install", `validating host requirements for "${executable.name}"`);
1112
- try {
1113
- await executable._validateHostRequirements(sdkLanguage);
1114
- import_debugLogger.debugLogger.log("install", `validation passed for ${executable.name}`);
1115
- } catch (error) {
1116
- import_debugLogger.debugLogger.log("install", `validation failed for ${executable.name}`);
1117
- throw error;
1118
- }
1119
- await import_fs.default.promises.writeFile(markerFile, "").catch(() => {
1120
- });
1121
- }
1122
- _downloadURLs(descriptor) {
1123
- const paths = DOWNLOAD_PATHS[descriptor.name];
1124
- const downloadPathTemplate = paths[import_hostPlatform.hostPlatform] || paths["<unknown>"];
1125
- if (!downloadPathTemplate)
1126
- return [];
1127
- let downloadPath;
1128
- let mirrors;
1129
- if (typeof downloadPathTemplate === "function") {
1130
- const result = downloadPathTemplate(descriptor);
1131
- downloadPath = result.path;
1132
- mirrors = result.mirrors;
1133
- } else {
1134
- downloadPath = util.format(downloadPathTemplate, descriptor.revision);
1135
- mirrors = PLAYWRIGHT_CDN_MIRRORS;
1136
- }
1137
- let downloadHostEnv;
1138
- if (descriptor.name.startsWith("chromium"))
1139
- downloadHostEnv = "PLAYWRIGHT_CHROMIUM_DOWNLOAD_HOST";
1140
- else if (descriptor.name.startsWith("firefox"))
1141
- downloadHostEnv = "PLAYWRIGHT_FIREFOX_DOWNLOAD_HOST";
1142
- else if (descriptor.name.startsWith("webkit"))
1143
- downloadHostEnv = "PLAYWRIGHT_WEBKIT_DOWNLOAD_HOST";
1144
- const customHostOverride = downloadHostEnv && (0, import_utils.getFromENV)(downloadHostEnv) || (0, import_utils.getFromENV)("PLAYWRIGHT_DOWNLOAD_HOST");
1145
- if (customHostOverride)
1146
- mirrors = [customHostOverride];
1147
- return mirrors.map((mirror) => `${mirror}/${downloadPath}`);
1148
- }
1149
- async _downloadExecutable(descriptor, force, executablePath) {
1150
- const downloadURLs = this._downloadURLs(descriptor);
1151
- if (!downloadURLs.length)
1152
- throw new Error(`ERROR: Playwright does not support ${descriptor.name} on ${import_hostPlatform.hostPlatform}`);
1153
- if (!import_hostPlatform.isOfficiallySupportedPlatform)
1154
- (0, import_browserFetcher.logPolitely)(`BEWARE: your OS is not officially supported by Playwright; downloading fallback build for ${import_hostPlatform.hostPlatform}.`);
1155
- if (descriptor.hasRevisionOverride) {
1156
- const message = `You are using a frozen ${descriptor.name} browser which does not receive updates anymore on ${import_hostPlatform.hostPlatform}. Please update to the latest version of your operating system to test up-to-date browsers.`;
1157
- if (process.env.GITHUB_ACTIONS)
1158
- console.log(`::warning title=Playwright::${message}`);
1159
- else
1160
- (0, import_browserFetcher.logPolitely)(message);
1161
- }
1162
- const title = this.calculateDownloadTitle(descriptor);
1163
- const downloadFileName = `playwright-download-${descriptor.name}-${import_hostPlatform.hostPlatform}-${descriptor.revision}.zip`;
1164
- const downloadSocketTimeoutEnv = (0, import_utils.getFromENV)("PLAYWRIGHT_DOWNLOAD_CONNECTION_TIMEOUT");
1165
- const downloadSocketTimeout = +(downloadSocketTimeoutEnv || "0") || import_network.NET_DEFAULT_TIMEOUT;
1166
- await (0, import_browserFetcher.downloadBrowserWithProgressBar)(title, descriptor.dir, executablePath, downloadURLs, downloadFileName, downloadSocketTimeout, force).catch((e) => {
1167
- throw new Error(`Failed to download ${title}, caused by
1168
- ${e.stack}`);
1169
- });
1170
- }
1171
- calculateDownloadTitle(descriptor) {
1172
- const title = descriptor.title ?? descriptor.name.split("-").map((word) => {
1173
- return word === "ffmpeg" ? "FFmpeg" : word.charAt(0).toUpperCase() + word.slice(1);
1174
- }).join(" ");
1175
- const version = descriptor.browserVersion ? " " + descriptor.browserVersion : "";
1176
- return `${title}${version} (playwright ${descriptor.name} v${descriptor.revision})`;
1177
- }
1178
- async _installMSEdgeChannel(channel, scripts) {
1179
- const scriptArgs = [];
1180
- if (process.platform !== "linux") {
1181
- const products = lowercaseAllKeys(JSON.parse(await (0, import_network.fetchData)(void 0, { url: "https://edgeupdates.microsoft.com/api/products" })));
1182
- const productName = {
1183
- "msedge": "Stable",
1184
- "msedge-beta": "Beta",
1185
- "msedge-dev": "Dev"
1186
- }[channel];
1187
- const product = products.find((product2) => product2.product === productName);
1188
- const searchConfig = {
1189
- darwin: { platform: "MacOS", arch: "universal", artifact: "pkg" },
1190
- win32: { platform: "Windows", arch: "x64", artifact: "msi" }
1191
- }[process.platform];
1192
- const release = searchConfig ? product.releases.find((release2) => release2.platform === searchConfig.platform && release2.architecture === searchConfig.arch && release2.artifacts.length > 0) : null;
1193
- const artifact = release ? release.artifacts.find((artifact2) => artifact2.artifactname === searchConfig.artifact) : null;
1194
- if (artifact)
1195
- scriptArgs.push(
1196
- artifact.location
1197
- /* url */
1198
- );
1199
- else
1200
- throw new Error(`Cannot install ${channel} on ${process.platform}`);
1201
- }
1202
- await this._installChromiumChannel(channel, scripts, scriptArgs);
1203
- }
1204
- async _installChromiumChannel(channel, scripts, scriptArgs = []) {
1205
- const scriptName = scripts[process.platform];
1206
- if (!scriptName)
1207
- throw new Error(`Cannot install ${channel} on ${process.platform}`);
1208
- const cwd = BIN_PATH;
1209
- const isPowerShell = scriptName.endsWith(".ps1");
1210
- if (isPowerShell) {
1211
- const args = [
1212
- "-ExecutionPolicy",
1213
- "Bypass",
1214
- "-File",
1215
- import_path.default.join(BIN_PATH, scriptName),
1216
- ...scriptArgs
1217
- ];
1218
- const { code } = await (0, import_spawnAsync.spawnAsync)("powershell.exe", args, { cwd, stdio: "inherit" });
1219
- if (code !== 0)
1220
- throw new Error(`Failed to install ${channel}`);
1221
- } else {
1222
- const { command, args, elevatedPermissions } = await (0, import_dependencies.transformCommandsForRoot)([`bash "${import_path.default.join(BIN_PATH, scriptName)}" ${scriptArgs.join("")}`]);
1223
- if (elevatedPermissions)
1224
- console.log("Switching to root user to install dependencies...");
1225
- const { code } = await (0, import_spawnAsync.spawnAsync)(command, args, { cwd, stdio: "inherit" });
1226
- if (code !== 0)
1227
- throw new Error(`Failed to install ${channel}`);
1228
- }
1229
- }
1230
- async listInstalledBrowsers() {
1231
- const linksDir = import_path.default.join(registryDirectory, ".links");
1232
- const { browsers } = await this._traverseBrowserInstallations(linksDir);
1233
- return browsers.filter((browser) => import_fs.default.existsSync(browser.browserPath));
1234
- }
1235
- async _validateInstallationCache(linksDir) {
1236
- const { browsers, brokenLinks } = await this._traverseBrowserInstallations(linksDir);
1237
- await this._deleteStaleBrowsers(browsers);
1238
- await this._deleteBrokenInstallations(brokenLinks);
1239
- }
1240
- async _traverseBrowserInstallations(linksDir) {
1241
- const browserList = [];
1242
- const brokenLinks = [];
1243
- for (const fileName of await import_fs.default.promises.readdir(linksDir)) {
1244
- const linkPath = import_path.default.join(linksDir, fileName);
1245
- let linkTarget = "";
1246
- try {
1247
- linkTarget = (await import_fs.default.promises.readFile(linkPath)).toString();
1248
- const browsersJSON = require(import_path.default.join(linkTarget, "browsers.json"));
1249
- const descriptors = readDescriptors(browsersJSON);
1250
- for (const browserName of allDownloadableDirectoriesThatEverExisted) {
1251
- const descriptor = descriptors.find((d) => d.name === browserName);
1252
- if (!descriptor)
1253
- continue;
1254
- const browserPath = descriptor.dir;
1255
- const browserVersion = parseInt(descriptor.revision, 10);
1256
- browserList.push({
1257
- browserName,
1258
- browserVersion,
1259
- browserPath,
1260
- referenceDir: linkTarget
1261
- });
1262
- }
1263
- } catch (e) {
1264
- brokenLinks.push(linkPath);
1265
- }
1266
- }
1267
- return { browsers: browserList, brokenLinks };
1268
- }
1269
- async _deleteStaleBrowsers(browserList) {
1270
- const usedBrowserPaths = /* @__PURE__ */ new Set();
1271
- for (const browser of browserList) {
1272
- const { browserName, browserVersion, browserPath } = browser;
1273
- const shouldHaveMarkerFile = browserName === "chromium" && (browserVersion >= 786218 || browserVersion < 3e5) || browserName === "firefox" && browserVersion >= 1128 || browserName === "webkit" && browserVersion >= 1307 || // All new applications have a marker file right away.
1274
- browserName !== "firefox" && browserName !== "chromium" && browserName !== "webkit";
1275
- if (!shouldHaveMarkerFile || await (0, import_fileUtils.existsAsync)(browserDirectoryToMarkerFilePath(browserPath)))
1276
- usedBrowserPaths.add(browserPath);
1277
- }
1278
- let downloadedBrowsers = (await import_fs.default.promises.readdir(registryDirectory)).map((file) => import_path.default.join(registryDirectory, file));
1279
- downloadedBrowsers = downloadedBrowsers.filter((file) => isBrowserDirectory(file));
1280
- const directories = new Set(downloadedBrowsers);
1281
- for (const browserDirectory of usedBrowserPaths)
1282
- directories.delete(browserDirectory);
1283
- for (const directory of directories)
1284
- (0, import_browserFetcher.logPolitely)("Removing unused browser at " + directory);
1285
- await (0, import_fileUtils.removeFolders)([...directories]);
1286
- }
1287
- async _deleteBrokenInstallations(brokenLinks) {
1288
- for (const linkPath of brokenLinks)
1289
- await import_fs.default.promises.unlink(linkPath).catch((e) => {
1290
- });
1291
- }
1292
- _defaultBrowsersToInstall(options) {
1293
- let executables = this.defaultExecutables();
1294
- if (options.shell === "no")
1295
- executables = executables.filter((e) => e.name !== "chromium-headless-shell" && e.name !== "chromium-tip-of-tree-headless-shell");
1296
- if (options.shell === "only")
1297
- executables = executables.filter((e) => e.name !== "chromium" && e.name !== "chromium-tip-of-tree");
1298
- return executables;
1299
- }
1300
- suggestedBrowsersToInstall() {
1301
- const names = this.executables().filter((e) => e.installType !== "none").map((e) => e.name);
1302
- names.push(...chromiumAliases);
1303
- return names.sort().join(", ");
1304
- }
1305
- isChromiumAlias(name) {
1306
- return chromiumAliases.includes(name);
1307
- }
1308
- resolveBrowsers(aliases, options) {
1309
- if (aliases.length === 0)
1310
- return this._defaultBrowsersToInstall(options);
1311
- const faultyArguments = [];
1312
- const executables = [];
1313
- const handleArgument = (arg) => {
1314
- const executable = this.findExecutable(arg);
1315
- if (!executable || executable.installType === "none")
1316
- faultyArguments.push(arg);
1317
- else
1318
- executables.push(executable);
1319
- if (executable?.browserName)
1320
- executables.push(this.findExecutable("ffmpeg"));
1321
- };
1322
- for (const alias of aliases) {
1323
- if (alias === "chromium" || chromiumAliases.includes(alias)) {
1324
- if (options.shell !== "only")
1325
- handleArgument("chromium");
1326
- if (options.shell !== "no")
1327
- handleArgument("chromium-headless-shell");
1328
- } else if (alias === "chromium-tip-of-tree") {
1329
- if (options.shell !== "only")
1330
- handleArgument("chromium-tip-of-tree");
1331
- if (options.shell !== "no")
1332
- handleArgument("chromium-tip-of-tree-headless-shell");
1333
- } else {
1334
- handleArgument(alias);
1335
- }
1336
- }
1337
- if (process.platform === "win32")
1338
- executables.push(this.findExecutable("winldd"));
1339
- if (faultyArguments.length)
1340
- throw new Error(`Invalid installation targets: ${faultyArguments.map((name) => `'${name}'`).join(", ")}. Expecting one of: ${this.suggestedBrowsersToInstall()}`);
1341
- return executables;
1342
- }
1343
- }
1344
- function browserDirectoryToMarkerFilePath(browserDirectory) {
1345
- return import_path.default.join(browserDirectory, "INSTALLATION_COMPLETE");
1346
- }
1347
- function buildPlaywrightCLICommand(sdkLanguage, parameters) {
1348
- switch (sdkLanguage) {
1349
- case "python":
1350
- return `playwright ${parameters}`;
1351
- case "java":
1352
- return `mvn exec:java -e -D exec.mainClass=com.microsoft.playwright.CLI -D exec.args="${parameters}"`;
1353
- case "csharp":
1354
- return `pwsh bin/Debug/netX/playwright.ps1 ${parameters}`;
1355
- default: {
1356
- const packageManagerCommand = (0, import_utils.getPackageManagerExecCommand)();
1357
- return `${packageManagerCommand} playwright ${parameters}`;
1358
- }
1359
- }
1360
- }
1361
- async function installBrowsersForNpmInstall(browsers) {
1362
- if ((0, import_utils.getAsBooleanFromENV)("PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD")) {
1363
- (0, import_browserFetcher.logPolitely)("Skipping browsers download because `PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD` env variable is set");
1364
- return false;
1365
- }
1366
- const executables = [];
1367
- if (process.platform === "win32")
1368
- executables.push(registry.findExecutable("winldd"));
1369
- for (const browserName of browsers) {
1370
- const executable = registry.findExecutable(browserName);
1371
- if (!executable || executable.installType === "none")
1372
- throw new Error(`Cannot install ${browserName}`);
1373
- executables.push(executable);
1374
- }
1375
- await registry.install(executables);
1376
- }
1377
- function findChromiumChannelBestEffort(sdkLanguage) {
1378
- let channel = null;
1379
- for (const name of ["chromium", "chrome", "msedge"]) {
1380
- try {
1381
- registry.findExecutable(name).executablePathOrDie(sdkLanguage);
1382
- channel = name === "chromium" ? void 0 : name;
1383
- break;
1384
- } catch (e) {
1385
- }
1386
- }
1387
- if (channel === null) {
1388
- const installCommand = buildPlaywrightCLICommand(sdkLanguage, `install chromium`);
1389
- const prettyMessage = [
1390
- `No chromium-based browser found on the system.`,
1391
- `Please run the following command to download one:`,
1392
- ``,
1393
- ` ${installCommand}`,
1394
- ``,
1395
- `<3 Playwright Team`
1396
- ].join("\n");
1397
- throw new Error("\n" + (0, import_ascii.wrapInASCIIBox)(prettyMessage, 1));
1398
- }
1399
- return channel;
1400
- }
1401
- function lowercaseAllKeys(json) {
1402
- if (typeof json !== "object" || !json)
1403
- return json;
1404
- if (Array.isArray(json))
1405
- return json.map(lowercaseAllKeys);
1406
- const result = {};
1407
- for (const [key, value] of Object.entries(json))
1408
- result[key.toLowerCase()] = lowercaseAllKeys(value);
1409
- return result;
1410
- }
1411
- const registry = new Registry(require("../../../browsers.json"));
1412
- // Annotate the CommonJS export names for ESM import in node:
1413
- 0 && (module.exports = {
1414
- Registry,
1415
- browserDirectoryToMarkerFilePath,
1416
- buildPlaywrightCLICommand,
1417
- findChromiumChannelBestEffort,
1418
- installBrowsersForNpmInstall,
1419
- registry,
1420
- registryDirectory,
1421
- writeDockerVersion
1422
- });