Skip to content

Commit 523c74d

Browse files
committed
add failing suggestions test
1 parent 0feb2bc commit 523c74d

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

packages/tailwindcss/src/intellisense.test.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -479,13 +479,13 @@ test('Custom functional @utility', async () => {
479479
}
480480
481481
@utility tab-* {
482-
tab-size: --value(--tab-size);
482+
tab-size: --value(--tab-size, 'revert', 'initial');
483483
}
484484
485485
@utility example-* {
486486
font-size: --value(--text);
487487
line-height: --value(--text- * --line-height);
488-
line-height: --modifier(--leading);
488+
line-height: --modifier(--leading, 'normal');
489489
}
490490
491491
@utility -negative-* {
@@ -507,6 +507,8 @@ test('Custom functional @utility', async () => {
507507
expect(classNames).toContain('tab-2')
508508
expect(classNames).toContain('tab-4')
509509
expect(classNames).toContain('tab-github')
510+
expect(classNames).toContain('tab-revert')
511+
expect(classNames).toContain('tab-initial')
510512

511513
expect(classNames).not.toContain('-tab-1')
512514
expect(classNames).not.toContain('-tab-2')
@@ -524,7 +526,7 @@ test('Custom functional @utility', async () => {
524526
expect(classNames).not.toContain('--negative-github')
525527

526528
expect(classNames).toContain('example-xs')
527-
expect(classMap.get('example-xs')?.modifiers).toEqual(['foo', 'bar'])
529+
expect(classMap.get('example-xs')?.modifiers).toEqual(['normal', 'foo', 'bar'])
528530
})
529531

530532
test('Theme keys with underscores are suggested with underscores', async () => {

0 commit comments

Comments
 (0)