test: avoid Windows temp alias in native integration

This commit is contained in:
reaper
2026-08-28 08:08:28 -05:00
parent 0503462d3d
commit 58baf10a39
3 changed files with 8 additions and 7 deletions
+2 -2
View File
@@ -1,12 +1,12 @@
{ {
"name": "aurora-dockside", "name": "aurora-dockside",
"version": "2.0.0-alpha.34", "version": "2.0.0-alpha.35",
"lockfileVersion": 3, "lockfileVersion": 3,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "aurora-dockside", "name": "aurora-dockside",
"version": "2.0.0-alpha.34", "version": "2.0.0-alpha.35",
"hasInstallScript": true, "hasInstallScript": true,
"dependencies": { "dependencies": {
"@electron-toolkit/preload": "^3.0.2", "@electron-toolkit/preload": "^3.0.2",
+1 -1
View File
@@ -1,6 +1,6 @@
{ {
"name": "aurora-dockside", "name": "aurora-dockside",
"version": "2.0.0-alpha.34", "version": "2.0.0-alpha.35",
"description": "A modern, modular Docker development platform for building, running, and managing web applications locally.", "description": "A modern, modular Docker development platform for building, running, and managing web applications locally.",
"desktopName": "aurora-dockside.desktop", "desktopName": "aurora-dockside.desktop",
"main": "./out/main/index.js", "main": "./out/main/index.js",
+5 -4
View File
@@ -2,7 +2,7 @@ import { execFile, spawn } from 'child_process'
import { createRequire } from 'module' import { createRequire } from 'module'
import { mkdtemp, readFile, writeFile } from 'fs/promises' import { mkdtemp, readFile, writeFile } from 'fs/promises'
import { tmpdir } from 'os' import { tmpdir } from 'os'
import { join, resolve } from 'path' import { dirname, join, resolve } from 'path'
import { promisify } from 'util' import { promisify } from 'util'
import { describe, expect, it } from 'vitest' import { describe, expect, it } from 'vitest'
import { import {
@@ -102,14 +102,15 @@ describe('native project configuration', () => {
it.runIf(Boolean(process.env.AURORA_NATIVE_SMOKE_ROOT))( it.runIf(Boolean(process.env.AURORA_NATIVE_SMOKE_ROOT))(
'serves PHP through the complete native stack', 'serves PHP through the complete native stack',
async () => { async () => {
const root = await mkdtemp(join(tmpdir(), 'aurora-native-project-')) const runtime = process.env.AURORA_NATIVE_SMOKE_ROOT!
const root = await mkdtemp(join(dirname(runtime), 'aurora-native-project-'))
await writeFile(join(root, 'index.php'), '<?php echo "aurora-native-ok";') await writeFile(join(root, 'index.php'), '<?php echo "aurora-native-ok";')
const definition = { const definition = {
name: `smoke-${Date.now()}`, name: `smoke-${Date.now()}`,
root, root,
docroot: '', docroot: '',
ports: await allocateNativePorts(), ports: await allocateNativePorts(),
installedRuntimeRoot: process.env.AURORA_NATIVE_SMOKE_ROOT installedRuntimeRoot: runtime
} }
try { try {
await startNativeProject(definition) await startNativeProject(definition)
@@ -126,7 +127,7 @@ it.runIf(Boolean(process.env.AURORA_NATIVE_WORDPRESS_SMOKE_ROOT))(
'provisions WordPress with the bundled native runtime', 'provisions WordPress with the bundled native runtime',
async () => { async () => {
const runtime = process.env.AURORA_NATIVE_WORDPRESS_SMOKE_ROOT! const runtime = process.env.AURORA_NATIVE_WORDPRESS_SMOKE_ROOT!
const root = await mkdtemp(join(tmpdir(), 'aurora-native-wordpress-')) const root = await mkdtemp(join(dirname(runtime), 'aurora-native-wordpress-'))
const definition = { const definition = {
name: `wordpress-${Date.now()}`, name: `wordpress-${Date.now()}`,
root, root,