add Sidebar tests

This commit is contained in:
Pulkit Sharma
2025-03-29 22:31:57 +05:30
parent 9e1186f5ac
commit 834eb0c934
3 changed files with 78 additions and 0 deletions

View File

@@ -318,6 +318,7 @@ const Sidebar = ({
{typeof configItem.value === "number" ? (
<Input
type="number"
data-testid={`${configKey}-input`}
value={configItem.value}
onChange={(e) => {
const newConfig = { ...config };
@@ -331,6 +332,7 @@ const Sidebar = ({
/>
) : typeof configItem.value === "boolean" ? (
<Select
data-testid={`${configKey}-select`}
value={configItem.value.toString()}
onValueChange={(val) => {
const newConfig = { ...config };
@@ -351,6 +353,7 @@ const Sidebar = ({
</Select>
) : (
<Input
data-testid={`${configKey}-input`}
value={configItem.value}
onChange={(e) => {
const newConfig = { ...config };