diff --git a/.github/workflows/node.yaml b/.github/workflows/node.yaml index 71bcd1b..6be3b8c 100644 --- a/.github/workflows/node.yaml +++ b/.github/workflows/node.yaml @@ -8,12 +8,21 @@ jobs: strategy: matrix: - os: [windows-2022] + os: [windows-2022, macos-14] node-version: ['18.x'] test-command: - npm run test-style - npm run test-types - npm run test-unit + exclude: + # The `test-style` script is platform-independent, so there is no + # value in executing it in multiple operating systems. + - os: macos-14 + test-command: npm run test-style + # The `test-types` script is platform-independent, so there is no + # value in executing it in multiple operating systems. + - os: macos-14 + test-command: npm run test-types steps: - uses: actions/checkout@v4 diff --git a/lib/commands/serve.js b/lib/commands/serve.js index 19b8679..4ac1a1f 100644 --- a/lib/commands/serve.js +++ b/lib/commands/serve.js @@ -6,8 +6,8 @@ const createCommandServer = require('../create-command-server'); const createVoiceServer = require('../create-voice-server'); const WINDOWS_NAMED_PIPE = '\\\\?\\pipe\\my_pipe'; -const MACOS_SYSTEM_DIR = '/usr/local/var/at_driver_generic'; -const MACOS_SOCKET_UNIX_PATH = '/usr/local/var/at_driver_generic/driver.socket'; +const MACOS_SYSTEM_DIR = '/tmp/at_driver_generic'; +const MACOS_SOCKET_UNIX_PATH = '/tmp/at_driver_generic/driver.socket'; const DEFAULT_PORT = 4382; /** diff --git a/src/macos/ATDriverGenericMacOS/ATDriverGenericService/ATDriverClientUnix.swift b/src/macos/ATDriverGenericMacOS/ATDriverGenericService/ATDriverClientUnix.swift index 38bb21f..f6930e0 100644 --- a/src/macos/ATDriverGenericMacOS/ATDriverGenericService/ATDriverClientUnix.swift +++ b/src/macos/ATDriverGenericMacOS/ATDriverGenericService/ATDriverClientUnix.swift @@ -25,7 +25,7 @@ class ATDriverClientUnix { } } - static let pipe = "/usr/local/var/at_driver_generic/driver.socket" + static let pipe = "/tmp/at_driver_generic/driver.socket" func sendInitEvent() throws { try self._sendEvent(name: "lifecycle", data: "hello") diff --git a/test/test.js b/test/test.js index 182656f..9c1d7d0 100644 --- a/test/test.js +++ b/test/test.js @@ -8,7 +8,7 @@ const WebSocket = require('ws'); const SOCKET_PATH = { win32: '\\\\?\\pipe\\my_pipe', - darwin: '/usr/local/var/at_driver_generic/driver.socket', + darwin: '/tmp/at_driver_generic/driver.socket', }[process.platform]; const executable = path.join(__dirname, '..', 'bin', 'at-driver');