mirror of
https://github.com/microsoft/vscode.git
synced 2026-05-08 09:08:48 +01:00
move remote and web tests to scripts folder
This commit is contained in:
@@ -86,11 +86,11 @@ jobs:
|
|||||||
|
|
||||||
- name: Run Integration Tests (Browser, Firefox)
|
- name: Run Integration Tests (Browser, Firefox)
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
run: .\resources\server\test\test-web-integration.bat --browser firefox
|
run: .\scripts\test-web-integration.bat --browser firefox
|
||||||
|
|
||||||
- name: Run Integration Tests (Remote)
|
- name: Run Integration Tests (Remote)
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
run: .\resources\server\test\test-remote-integration.bat
|
run: .\scripts\test-remote-integration.bat
|
||||||
|
|
||||||
linux:
|
linux:
|
||||||
name: Linux
|
name: Linux
|
||||||
@@ -167,12 +167,12 @@ jobs:
|
|||||||
|
|
||||||
- name: Run Integration Tests (Browser, Chromium)
|
- name: Run Integration Tests (Browser, Chromium)
|
||||||
id: browser-integration-tests
|
id: browser-integration-tests
|
||||||
run: DISPLAY=:10 ./resources/server/test/test-web-integration.sh --browser chromium
|
run: DISPLAY=:10 ./scripts/test-web-integration.sh --browser chromium
|
||||||
|
|
||||||
- name: Run Integration Tests (Remote)
|
- name: Run Integration Tests (Remote)
|
||||||
id: electron-remote-integration-tests
|
id: electron-remote-integration-tests
|
||||||
timeout-minutes: 15
|
timeout-minutes: 15
|
||||||
run: DISPLAY=:10 ./resources/server/test/test-remote-integration.sh
|
run: DISPLAY=:10 ./scripts/test-remote-integration.sh
|
||||||
|
|
||||||
darwin:
|
darwin:
|
||||||
name: macOS
|
name: macOS
|
||||||
@@ -242,11 +242,11 @@ jobs:
|
|||||||
run: DISPLAY=:10 ./scripts/test-integration.sh
|
run: DISPLAY=:10 ./scripts/test-integration.sh
|
||||||
|
|
||||||
- name: Run Integration Tests (Browser, Webkit)
|
- name: Run Integration Tests (Browser, Webkit)
|
||||||
run: DISPLAY=:10 ./resources/server/test/test-web-integration.sh --browser webkit
|
run: DISPLAY=:10 ./scripts/test-web-integration.sh --browser webkit
|
||||||
|
|
||||||
- name: Run Integration Tests (Remote)
|
- name: Run Integration Tests (Remote)
|
||||||
timeout-minutes: 15
|
timeout-minutes: 15
|
||||||
run: DISPLAY=:10 ./resources/server/test/test-remote-integration.sh
|
run: DISPLAY=:10 ./scripts/test-remote-integration.sh
|
||||||
|
|
||||||
hygiene:
|
hygiene:
|
||||||
name: Hygiene, Layering and Monaco Editor
|
name: Hygiene, Layering and Monaco Editor
|
||||||
|
|||||||
@@ -208,7 +208,7 @@ steps:
|
|||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-web-darwin" \
|
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-web-darwin" \
|
||||||
./resources/server/test/test-web-integration.sh --browser webkit
|
./scripts/test-web-integration.sh --browser webkit
|
||||||
displayName: Run integration tests (Browser, Webkit)
|
displayName: Run integration tests (Browser, Webkit)
|
||||||
timeoutInMinutes: 10
|
timeoutInMinutes: 10
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
@@ -219,7 +219,7 @@ steps:
|
|||||||
APP_NAME="`ls $APP_ROOT | head -n 1`"
|
APP_NAME="`ls $APP_ROOT | head -n 1`"
|
||||||
INTEGRATION_TEST_ELECTRON_PATH="$APP_ROOT/$APP_NAME/Contents/MacOS/Electron" \
|
INTEGRATION_TEST_ELECTRON_PATH="$APP_ROOT/$APP_NAME/Contents/MacOS/Electron" \
|
||||||
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-darwin" \
|
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-darwin" \
|
||||||
./resources/server/test/test-remote-integration.sh
|
./scripts/test-remote-integration.sh
|
||||||
displayName: Run integration tests (Remote)
|
displayName: Run integration tests (Remote)
|
||||||
timeoutInMinutes: 10
|
timeoutInMinutes: 10
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
|
|||||||
@@ -205,7 +205,7 @@ steps:
|
|||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-web-linux-$(VSCODE_ARCH)" \
|
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-web-linux-$(VSCODE_ARCH)" \
|
||||||
./resources/server/test/test-web-integration.sh --browser chromium
|
./scripts/test-web-integration.sh --browser chromium
|
||||||
displayName: Run integration tests (Browser, Chromium)
|
displayName: Run integration tests (Browser, Chromium)
|
||||||
timeoutInMinutes: 10
|
timeoutInMinutes: 10
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
@@ -217,7 +217,7 @@ steps:
|
|||||||
INTEGRATION_TEST_APP_NAME="$APP_NAME" \
|
INTEGRATION_TEST_APP_NAME="$APP_NAME" \
|
||||||
INTEGRATION_TEST_ELECTRON_PATH="$APP_ROOT/$APP_NAME" \
|
INTEGRATION_TEST_ELECTRON_PATH="$APP_ROOT/$APP_NAME" \
|
||||||
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-linux-$(VSCODE_ARCH)" \
|
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-linux-$(VSCODE_ARCH)" \
|
||||||
./resources/server/test/test-remote-integration.sh
|
./scripts/test-remote-integration.sh
|
||||||
displayName: Run integration tests (Remote)
|
displayName: Run integration tests (Remote)
|
||||||
timeoutInMinutes: 7
|
timeoutInMinutes: 7
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
|
|||||||
@@ -189,7 +189,7 @@ steps:
|
|||||||
- powershell: |
|
- powershell: |
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
. build/azure-pipelines/win32/exec.ps1
|
||||||
$ErrorActionPreference = "Stop"
|
$ErrorActionPreference = "Stop"
|
||||||
exec { $env:VSCODE_REMOTE_SERVER_PATH = "$(agent.builddirectory)\vscode-reh-web-win32-$(VSCODE_ARCH)"; .\resources\server\test\test-web-integration.bat --browser firefox }
|
exec { $env:VSCODE_REMOTE_SERVER_PATH = "$(agent.builddirectory)\vscode-reh-web-win32-$(VSCODE_ARCH)"; .\scripts\test-web-integration.bat --browser firefox }
|
||||||
displayName: Run integration tests (Browser, Firefox)
|
displayName: Run integration tests (Browser, Firefox)
|
||||||
timeoutInMinutes: 10
|
timeoutInMinutes: 10
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
||||||
@@ -200,7 +200,7 @@ steps:
|
|||||||
$AppRoot = "$(agent.builddirectory)\VSCode-win32-$(VSCODE_ARCH)"
|
$AppRoot = "$(agent.builddirectory)\VSCode-win32-$(VSCODE_ARCH)"
|
||||||
$AppProductJson = Get-Content -Raw -Path "$AppRoot\resources\app\product.json" | ConvertFrom-Json
|
$AppProductJson = Get-Content -Raw -Path "$AppRoot\resources\app\product.json" | ConvertFrom-Json
|
||||||
$AppNameShort = $AppProductJson.nameShort
|
$AppNameShort = $AppProductJson.nameShort
|
||||||
exec { $env:INTEGRATION_TEST_ELECTRON_PATH = "$AppRoot\$AppNameShort.exe"; $env:VSCODE_REMOTE_SERVER_PATH = "$(agent.builddirectory)\vscode-reh-win32-$(VSCODE_ARCH)"; .\resources\server\test\test-remote-integration.bat }
|
exec { $env:INTEGRATION_TEST_ELECTRON_PATH = "$AppRoot\$AppNameShort.exe"; $env:VSCODE_REMOTE_SERVER_PATH = "$(agent.builddirectory)\vscode-reh-win32-$(VSCODE_ARCH)"; .\scripts\test-remote-integration.bat }
|
||||||
displayName: Run integration tests (Remote)
|
displayName: Run integration tests (Remote)
|
||||||
timeoutInMinutes: 7
|
timeoutInMinutes: 7
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ call yarn gulp node
|
|||||||
|
|
||||||
:: Launch Server
|
:: Launch Server
|
||||||
FOR /F "tokens=*" %%g IN ('node build/lib/node.js') do (SET NODE=%%g)
|
FOR /F "tokens=*" %%g IN ('node build/lib/node.js') do (SET NODE=%%g)
|
||||||
call "%NODE%" resources\server\bin-dev\code-server.js %*
|
call "%NODE%" scripts\code-server.js %*
|
||||||
|
|
||||||
popd
|
popd
|
||||||
|
|
||||||
|
|||||||
@@ -50,10 +50,8 @@ if (args['port'] === undefined) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const env = { ...process.env };
|
const env = { ...process.env };
|
||||||
env['NODE_ENV'] = 'development';
|
|
||||||
env['VSCODE_DEV'] = '1';
|
|
||||||
const entryPoint = path.join(__dirname, '..', '..', '..', 'out', 'server-main.js');
|
|
||||||
|
|
||||||
|
const entryPoint = path.join(__dirname, '..', 'out', 'server-main.js');
|
||||||
startServer();
|
startServer();
|
||||||
|
|
||||||
function startServer() {
|
function startServer() {
|
||||||
@@ -20,7 +20,7 @@ function code() {
|
|||||||
|
|
||||||
NODE_ENV=development \
|
NODE_ENV=development \
|
||||||
VSCODE_DEV=1 \
|
VSCODE_DEV=1 \
|
||||||
$NODE ./resources/server/bin-dev/code-server.js "$@"
|
$NODE ./scripts/code-server.js "$@"
|
||||||
}
|
}
|
||||||
|
|
||||||
code "$@"
|
code "$@"
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ call yarn gulp node
|
|||||||
|
|
||||||
:: Launch Server
|
:: Launch Server
|
||||||
FOR /F "tokens=*" %%g IN ('node build/lib/node.js') do (SET NODE=%%g)
|
FOR /F "tokens=*" %%g IN ('node build/lib/node.js') do (SET NODE=%%g)
|
||||||
call "%NODE%" resources\web\bin-dev\code-web-playground.js %*
|
call "%NODE%" scripts\code-web.js %*
|
||||||
|
|
||||||
popd
|
popd
|
||||||
|
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ const remote = require('gulp-remote-retry-src');
|
|||||||
const vfs = require('vinyl-fs');
|
const vfs = require('vinyl-fs');
|
||||||
const opn = require('opn');
|
const opn = require('opn');
|
||||||
|
|
||||||
const APP_ROOT = path.join(__dirname, '..', '..', '..');
|
const APP_ROOT = path.join(__dirname, '..');
|
||||||
const WEB_DEV_EXTENSIONS_ROOT = path.join(APP_ROOT, '.build', 'builtInWebDevExtensions');
|
const WEB_DEV_EXTENSIONS_ROOT = path.join(APP_ROOT, '.build', 'builtInWebDevExtensions');
|
||||||
|
|
||||||
const WEB_PLAYGROUND_VERSION = '0.0.13';
|
const WEB_PLAYGROUND_VERSION = '0.0.13';
|
||||||
+1
-1
@@ -18,7 +18,7 @@ function code() {
|
|||||||
|
|
||||||
NODE=$(node build/lib/node.js)
|
NODE=$(node build/lib/node.js)
|
||||||
|
|
||||||
$NODE ./resources/web/bin-dev/code-web-playground.js "$@"
|
$NODE ./scripts/code-web.js "$@"
|
||||||
}
|
}
|
||||||
|
|
||||||
code "$@"
|
code "$@"
|
||||||
|
|||||||
+3
-3
@@ -1,7 +1,7 @@
|
|||||||
@echo off
|
@echo off
|
||||||
setlocal
|
setlocal
|
||||||
|
|
||||||
pushd %~dp0\..\..\..
|
pushd %~dp0\..
|
||||||
|
|
||||||
IF "%~1" == "" (
|
IF "%~1" == "" (
|
||||||
set AUTHORITY=vscode-remote://test+test/
|
set AUTHORITY=vscode-remote://test+test/
|
||||||
@@ -20,8 +20,8 @@ IF "%VSCODEUSERDATADIR%" == "" (
|
|||||||
)
|
)
|
||||||
|
|
||||||
set REMOTE_VSCODE=%AUTHORITY%%EXT_PATH%
|
set REMOTE_VSCODE=%AUTHORITY%%EXT_PATH%
|
||||||
set VSCODECRASHDIR=%~dp0\..\..\..\.build\crashes
|
set VSCODECRASHDIR=%~dp0\..\.build\crashes
|
||||||
set VSCODELOGSDIR=%~dp0\..\..\..\.build\logs\integration-tests-remote
|
set VSCODELOGSDIR=%~dp0\..\.build\logs\integration-tests-remote
|
||||||
set TESTRESOLVER_DATA_FOLDER=%TMP%\testresolverdatafolder-%RANDOM%-%TIME:~6,5%
|
set TESTRESOLVER_DATA_FOLDER=%TMP%\testresolverdatafolder-%RANDOM%-%TIME:~6,5%
|
||||||
set TESTRESOLVER_LOGS_FOLDER=%VSCODELOGSDIR%\server
|
set TESTRESOLVER_LOGS_FOLDER=%VSCODELOGSDIR%\server
|
||||||
|
|
||||||
+2
-2
@@ -3,11 +3,11 @@ set -e
|
|||||||
|
|
||||||
if [[ "$OSTYPE" == "darwin"* ]]; then
|
if [[ "$OSTYPE" == "darwin"* ]]; then
|
||||||
realpath() { [[ $1 = /* ]] && echo "$1" || echo "$PWD/${1#./}"; }
|
realpath() { [[ $1 = /* ]] && echo "$1" || echo "$PWD/${1#./}"; }
|
||||||
ROOT=$(dirname $(dirname $(dirname $(dirname $(realpath "$0")))))
|
ROOT=$(dirname $(dirname $(realpath "$0")))
|
||||||
VSCODEUSERDATADIR=`mktemp -d -t 'myuserdatadir'`
|
VSCODEUSERDATADIR=`mktemp -d -t 'myuserdatadir'`
|
||||||
TESTRESOLVER_DATA_FOLDER=`mktemp -d -t 'testresolverdatafolder'`
|
TESTRESOLVER_DATA_FOLDER=`mktemp -d -t 'testresolverdatafolder'`
|
||||||
else
|
else
|
||||||
ROOT=$(dirname $(dirname $(dirname $(dirname $(readlink -f $0)))))
|
ROOT=$(dirname $(dirname $(readlink -f $0)))
|
||||||
VSCODEUSERDATADIR=`mktemp -d 2>/dev/null`
|
VSCODEUSERDATADIR=`mktemp -d 2>/dev/null`
|
||||||
TESTRESOLVER_DATA_FOLDER=`mktemp -d 2>/dev/null`
|
TESTRESOLVER_DATA_FOLDER=`mktemp -d 2>/dev/null`
|
||||||
# --disable-dev-shm-usage --use-gl=swiftshader: when run on docker containers where size of /dev/shm
|
# --disable-dev-shm-usage --use-gl=swiftshader: when run on docker containers where size of /dev/shm
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
@echo off
|
@echo off
|
||||||
setlocal
|
setlocal
|
||||||
|
|
||||||
pushd %~dp0\..\..\..
|
pushd %~dp0\..
|
||||||
|
|
||||||
IF "%~1" == "" (
|
IF "%~1" == "" (
|
||||||
set AUTHORITY=vscode-remote://test+test/
|
set AUTHORITY=vscode-remote://test+test/
|
||||||
@@ -3,9 +3,9 @@ set -e
|
|||||||
|
|
||||||
if [[ "$OSTYPE" == "darwin"* ]]; then
|
if [[ "$OSTYPE" == "darwin"* ]]; then
|
||||||
realpath() { [[ $1 = /* ]] && echo "$1" || echo "$PWD/${1#./}"; }
|
realpath() { [[ $1 = /* ]] && echo "$1" || echo "$PWD/${1#./}"; }
|
||||||
ROOT=$(dirname $(dirname $(dirname $(dirname $(realpath "$0")))))
|
ROOT=$(dirname $(dirname $(realpath "$0")))
|
||||||
else
|
else
|
||||||
ROOT=$(dirname $(dirname $(dirname $(dirname $(readlink -f $0)))))
|
ROOT=$(dirname $(dirname $(readlink -f $0)))
|
||||||
fi
|
fi
|
||||||
|
|
||||||
cd $ROOT
|
cd $ROOT
|
||||||
@@ -15,7 +15,7 @@ All integration tests run in an Electron instance. You can specify to run the te
|
|||||||
|
|
||||||
## Run (inside browser)
|
## Run (inside browser)
|
||||||
|
|
||||||
resources/server/test/test-web-integration.[sh|bat] --browser [chromium|webkit] [--debug]
|
scripts/test-web-integration.[sh|bat] --browser [chromium|webkit] [--debug]
|
||||||
|
|
||||||
All integration tests run in a browser instance as specified by the command line arguments.
|
All integration tests run in a browser instance as specified by the command line arguments.
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user