From e5f6e9afcb5cf61c15fe70a4a9aa3e745d9692e4 Mon Sep 17 00:00:00 2001 From: Philipp Hancke Date: Sat, 20 Apr 2024 15:59:04 -0700 Subject: [PATCH] test: use path.join to join path to browser --- test/karma.conf.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/test/karma.conf.js b/test/karma.conf.js index 23130246..ba4fb2c8 100644 --- a/test/karma.conf.js +++ b/test/karma.conf.js @@ -9,6 +9,7 @@ 'use strict'; const os = require('os'); +const path = require('path'); const puppeteerBrowsers = require('@puppeteer/browsers'); async function download(browser, version, cacheDir, platform) { @@ -20,11 +21,12 @@ async function download(browser, version, cacheDir, platform) { cacheDir, platform }); + console.error(browser, version, platform, buildId); return buildId; } module.exports = async(config) => { - const cacheDir = process.cwd() + '/browsers'; + const cacheDir = path.join(process.cwd(), 'browsers'); const platform = puppeteerBrowsers.detectBrowserPlatform(); let browsers; @@ -43,6 +45,7 @@ module.exports = async(config) => { } else { browsers = ['chrome', 'firefox']; } + console.error('BROWSERS', browser); let reporters = ['mocha']; if (process.env.CI) {