We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 308578a commit c817f10Copy full SHA for c817f10
tests/validation.test.js
@@ -13,6 +13,19 @@ test('form', () => {
13
expect(isValidHTMLNesting('form', 'h1')).toBe(true);
14
});
15
16
+test('select', () => {
17
+ // invalid
18
+ expect(isValidHTMLNesting('select', 'select')).toBe(false);
19
+ expect(isValidHTMLNesting('select', 'p')).toBe(false);
20
+ expect(isValidHTMLNesting('select', 'h1')).toBe(false);
21
+
22
+ // valid
23
+ expect(isValidHTMLNesting('select', 'option')).toBe(true);
24
+ expect(isValidHTMLNesting('select', 'optgroup')).toBe(true);
25
+ expect(isValidHTMLNesting('select', 'hr')).toBe(true);
26
+ expect(isValidHTMLNesting('select', 'button')).toBe(true);
27
+});
28
29
test('p', () => {
30
// invalid
31
expect(isValidHTMLNesting('p', 'p')).toBe(false);
0 commit comments