Testing Model Selection Component Workflow in OpenHands
This test suite evaluates the ModelSelector component’s functionality in the OpenHands frontend. It covers critical user interface interactions and state management for AI model selection. The tests ensure proper handling of provider and model selection, disabled states, and initial model configuration.
Test Coverage Overview
Implementation Analysis
Technical Details
Best Practices Demonstrated
all-hands-ai/openhands
frontend/__tests__/components/settings/model-selector.test.tsx
import { describe, it } from "vitest";
describe("ModelSelector", () => {
it.todo("should render the model selector");
it.todo("should display and select the providers");
it.todo("should display and select the models");
it.todo("should disable the models if a provider is not selected");
it.todo("should disable the inputs if isDisabled is true");
it.todo(
"should set the selected model and provider if the currentModel prop is set",
);
});