/** * @jsxImportSource @solidjs/web * * #4891: a bound ` at render time (#4891)", () => { test("options from a match the select's value", () => { const [v] = createSignal("b"); const html = renderToString(() => ( )); expect(selected(html)).toEqual(["b"]); expect(html).not.toMatch(/]*value/); }); test("options from a component and a match", () => { const Opt = (props: { v: string }) => ; const html = renderToString(() => ( )); expect(selected(html)).toEqual(["c"]); }); test("an option from a signal-driven matches", () => { const [show] = createSignal(true); const html = renderToString(() => ( )); expect(selected(html)).toEqual(["b"]); }); test("an option from a signal-driven && matches", () => { const [show] = createSignal(true); const html = renderToString(() => ( )); expect(selected(html)).toEqual(["b"]); }); test("an option from a signal-driven ternary matches", () => { const [show] = createSignal(true); const html = renderToString(() => ( )); expect(selected(html)).toEqual(["b"]); }); test("an option's text is its value when it has no value attribute", () => { const [label] = createSignal("Two"); const html = renderToString(() => ( )); expect(html).toMatch(/