|
3 | 3 | * Licensed under the MIT License. See License.txt in the project root for license information.
|
4 | 4 | *--------------------------------------------------------------------------------------------*/
|
5 | 5 |
|
6 |
| -import { testCompletionFor, testTagCompletion } from "./completionUtil"; |
| 6 | +import { testCompletionFor, testQuoteCompletion, testTagCompletion } from "./completionUtil"; |
7 | 7 |
|
8 | 8 | suite('HTML Completion', () => {
|
9 | 9 | test('Complete', function (): any {
|
@@ -428,6 +428,19 @@ suite('HTML Completion', () => {
|
428 | 428 | );
|
429 | 429 | });
|
430 | 430 |
|
| 431 | + test('doQuoteComplete', function (): any { |
| 432 | + testQuoteCompletion('<a foo=|', '""'); |
| 433 | + testQuoteCompletion('<a foo=|', '\'\'', { attributeDefaultValue: 'singlequotes'}); |
| 434 | + testQuoteCompletion('<a foo=|', null, { attributeDefaultValue: 'empty'}); |
| 435 | + testQuoteCompletion('<a foo=|=', null); |
| 436 | + testQuoteCompletion('<a foo=|></a>', '""'); |
| 437 | + testQuoteCompletion('<a foo="bar=|"', null); |
| 438 | + testQuoteCompletion('<a baz=| foo="bar">', '""'); |
| 439 | + testQuoteCompletion('<a>< foo=| /a>', null); |
| 440 | + testQuoteCompletion('<a></ foo=| a>', null); |
| 441 | + testQuoteCompletion('<a foo="bar" \n baz=| ></a>', '""'); |
| 442 | + }); |
| 443 | + |
431 | 444 | test('doTagComplete', function (): any {
|
432 | 445 | testTagCompletion('<div>|', '$0</div>');
|
433 | 446 | testTagCompletion('<div>|</div>', null);
|
|
0 commit comments