提交 4c81ed50 编写于 作者: M Martin Aeschlimann

include json/css in integration tests

上级 ab90818c
...@@ -10,7 +10,7 @@ import { getCSSLanguageService, getSCSSLanguageService } from 'vscode-css-langua ...@@ -10,7 +10,7 @@ import { getCSSLanguageService, getSCSSLanguageService } from 'vscode-css-langua
import { TextDocument, CompletionList } from 'vscode-languageserver-types'; import { TextDocument, CompletionList } from 'vscode-languageserver-types';
import { getEmmetCompletionParticipants } from 'vscode-emmet-helper'; import { getEmmetCompletionParticipants } from 'vscode-emmet-helper';
suite('Emmet Support', () => { suite('CSS Emmet Support', () => {
const cssLanguageService = getCSSLanguageService(); const cssLanguageService = getCSSLanguageService();
const scssLanguageService = getSCSSLanguageService(); const scssLanguageService = getSCSSLanguageService();
...@@ -44,6 +44,8 @@ suite('Emmet Support', () => { ...@@ -44,6 +44,8 @@ suite('Emmet Support', () => {
} }
test('Css Emmet Completions', function (): any { test('Css Emmet Completions', function (): any {
this.skip(); // disabled again (see #29113)
assertCompletions('css', '.foo { display: none; m10| }', 'margin: 10px;', 'margin: 10px;'); assertCompletions('css', '.foo { display: none; m10| }', 'margin: 10px;', 'margin: 10px;');
assertCompletions('css', 'foo { display: none; pos:f| }', 'position: fixed;', 'position: fixed;'); assertCompletions('css', 'foo { display: none; pos:f| }', 'position: fixed;', 'position: fixed;');
assertCompletions('css', 'foo { display: none; margin: a| }', null, null); assertCompletions('css', 'foo { display: none; margin: a| }', null, null);
...@@ -55,6 +57,8 @@ suite('Emmet Support', () => { ...@@ -55,6 +57,8 @@ suite('Emmet Support', () => {
}); });
test('Scss Emmet Completions', function (): any { test('Scss Emmet Completions', function (): any {
this.skip(); // disabled again (see #29113)
assertCompletions('scss', '.foo { display: none; .bar { m10| } }', 'margin: 10px;', 'margin: 10px;'); assertCompletions('scss', '.foo { display: none; .bar { m10| } }', 'margin: 10px;', 'margin: 10px;');
assertCompletions('scss', 'foo { display: none; .bar { pos:f| } }', 'position: fixed;', 'position: fixed;'); assertCompletions('scss', 'foo { display: none; .bar { pos:f| } }', 'position: fixed;', 'position: fixed;');
assertCompletions('scss', 'foo { display: none; margin: a| .bar {}}', null, null); assertCompletions('scss', 'foo { display: none; margin: a| .bar {}}', null, null);
...@@ -64,5 +68,4 @@ suite('Emmet Support', () => { ...@@ -64,5 +68,4 @@ suite('Emmet Support', () => {
assertCompletions('scss', 'foo { display: none|; }', null, null); assertCompletions('scss', 'foo { display: none|; }', null, null);
assertCompletions('scss', '.foo { display: none; -m-m10| }', 'margin: 10px;', '-moz-margin: 10px;\nmargin: 10px;'); assertCompletions('scss', '.foo { display: none; -m-m10| }', 'margin: 10px;', '-moz-margin: 10px;\nmargin: 10px;');
}); });
}); });
\ No newline at end of file
...@@ -22,7 +22,7 @@ export interface ItemDescription { ...@@ -22,7 +22,7 @@ export interface ItemDescription {
} }
suite('Completions', () => { suite('HTML Completions', () => {
let assertCompletion = function (completions: CompletionList, expected: ItemDescription, document: TextDocument, offset: number) { let assertCompletion = function (completions: CompletionList, expected: ItemDescription, document: TextDocument, offset: number) {
let matches = completions.items.filter(completion => { let matches = completions.items.filter(completion => {
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
import * as assert from 'assert'; import * as assert from 'assert';
import { getDocumentContext } from '../utils/documentContext'; import { getDocumentContext } from '../utils/documentContext';
suite('Document Context', () => { suite('HTML Document Context', () => {
test('Context', function (): any { test('Context', function (): any {
const docURI = 'file:///users/test/folder/test.html'; const docURI = 'file:///users/test/folder/test.html';
......
...@@ -15,7 +15,7 @@ import * as embeddedSupport from '../modes/embeddedSupport'; ...@@ -15,7 +15,7 @@ import * as embeddedSupport from '../modes/embeddedSupport';
import { getEmmetCompletionParticipants } from 'vscode-emmet-helper'; import { getEmmetCompletionParticipants } from 'vscode-emmet-helper';
import { getCSSMode } from '../modes/cssMode'; import { getCSSMode } from '../modes/cssMode';
suite('Emmet Support', () => { suite('HTML Emmet Support', () => {
const htmlLanguageService = getLanguageService(); const htmlLanguageService = getLanguageService();
......
...@@ -34,7 +34,7 @@ function r(startLine: number, endLine: number, type?: string): ExpectedIndentRan ...@@ -34,7 +34,7 @@ function r(startLine: number, endLine: number, type?: string): ExpectedIndentRan
return { startLine, endLine, type }; return { startLine, endLine, type };
} }
suite('Object Folding', () => { suite('HTML Folding', () => {
test('Fold one level', () => { test('Fold one level', () => {
let input = [ let input = [
/*0*/'<html>', /*0*/'<html>',
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
import * as assert from 'assert'; import * as assert from 'assert';
import * as words from '../utils/strings'; import * as words from '../utils/strings';
suite('Words', () => { suite('HTML Words', () => {
let wordRegex = /(-?\d*\.\d\w*)|([^\`\~\!\@\#\%\^\&\*\(\)\-\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g; let wordRegex = /(-?\d*\.\d\w*)|([^\`\~\!\@\#\%\^\&\*\(\)\-\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g;
......
...@@ -32,7 +32,7 @@ function r(startLine: number, endLine: number, type?: string): ExpectedIndentRan ...@@ -32,7 +32,7 @@ function r(startLine: number, endLine: number, type?: string): ExpectedIndentRan
return { startLine, endLine, type }; return { startLine, endLine, type };
} }
suite('Object Folding', () => { suite('JSON Folding', () => {
test('Fold one level', () => { test('Fold one level', () => {
let input = [ let input = [
/*0*/'{', /*0*/'{',
......
...@@ -25,8 +25,8 @@ if %errorlevel% neq 0 exit /b %errorlevel% ...@@ -25,8 +25,8 @@ if %errorlevel% neq 0 exit /b %errorlevel%
call .\scripts\test.bat --runGlob **\*.integrationTest.js %* call .\scripts\test.bat --runGlob **\*.integrationTest.js %*
if %errorlevel% neq 0 exit /b %errorlevel% if %errorlevel% neq 0 exit /b %errorlevel%
:: Tests in commonJS (language servers tests...) # Tests in commonJS (HTML, CSS, JSON language server tests...)
call .\scripts\node-electron.bat .\node_modules\mocha\bin\_mocha .\extensions\html-language-features\server\out\test\ call .\scripts\node-electron.bat .\node_modules\mocha\bin\_mocha .\extensions\*\server\out\test\
if %errorlevel% neq 0 exit /b %errorlevel% if %errorlevel% neq 0 exit /b %errorlevel%
rmdir /s /q %VSCODEUSERDATADIR% rmdir /s /q %VSCODEUSERDATADIR%
......
...@@ -23,7 +23,7 @@ rm -r $ROOT/extensions/emmet/test-fixtures ...@@ -23,7 +23,7 @@ rm -r $ROOT/extensions/emmet/test-fixtures
# Integration tests in AMD # Integration tests in AMD
./scripts/test.sh --runGlob **/*.integrationTest.js "$@" ./scripts/test.sh --runGlob **/*.integrationTest.js "$@"
# Tests in commonJS (language server tests...) # Tests in commonJS (HTML, CSS, JSON language server tests...)
./scripts/node-electron.sh ./node_modules/mocha/bin/_mocha ./extensions/html-language-features/server/out/test/ ./scripts/node-electron.sh ./node_modules/mocha/bin/_mocha ./extensions/*/server/out/test/
rm -r $VSCODEUSERDATADIR rm -r $VSCODEUSERDATADIR
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册