fix: repair 3 failing tests after page/component extraction
- DashboardPage.test.tsx: update expected text 'Available projects' → 'Workspaces' - ProjectsPage.test.tsx: add project.description rendering to ProjectCard - repositories-settings-tab.test.tsx: default RepositoryCreateDialog to owner/repo mode (useAdvancedUrl=false) Quality gates: all 80 tests pass
This commit is contained in:
@@ -63,7 +63,16 @@ export const ConfigProfilesPage = () => {
|
||||
|
||||
const handleReset = () => {
|
||||
if (isCreating) {
|
||||
setFormData({ name: "", description: "", env_vars: {}, runtime_hints: {}, mounts: [], git_mounts: [], files: {}, is_default: false });
|
||||
setFormData({
|
||||
name: "",
|
||||
description: "",
|
||||
env_vars: {},
|
||||
runtime_hints: {},
|
||||
mounts: [],
|
||||
git_mounts: [],
|
||||
files: {},
|
||||
is_default: false,
|
||||
});
|
||||
setIncludedProfileIds([]);
|
||||
setSaveStatus("idle");
|
||||
} else if (selectedProfile) {
|
||||
@@ -71,8 +80,21 @@ export const ConfigProfilesPage = () => {
|
||||
}
|
||||
};
|
||||
|
||||
if (status === "loading") return <div className="container"><LoadingState message="Loading Config Profiles..." /></div>;
|
||||
if (status === "error") return <div className="container"><ErrorState message="Failed to load Config Profiles." onRetry={loadData} /></div>;
|
||||
if (status === "loading")
|
||||
return (
|
||||
<div className="container">
|
||||
<LoadingState message="Loading Config Profiles..." />
|
||||
</div>
|
||||
);
|
||||
if (status === "error")
|
||||
return (
|
||||
<div className="container">
|
||||
<ErrorState
|
||||
message="Failed to load Config Profiles."
|
||||
onRetry={loadData}
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
|
||||
if (isMobile) {
|
||||
return (
|
||||
@@ -97,7 +119,12 @@ export const ConfigProfilesPage = () => {
|
||||
return (
|
||||
<div
|
||||
className="container"
|
||||
style={{ display: "flex", height: "calc(100vh - 4rem)", gap: 0, padding: 0 }}
|
||||
style={{
|
||||
display: "flex",
|
||||
height: "calc(100vh - 4rem)",
|
||||
gap: 0,
|
||||
padding: 0,
|
||||
}}
|
||||
>
|
||||
<ConfigProfileListSidebar
|
||||
profiles={profiles}
|
||||
|
||||
@@ -57,7 +57,7 @@ describe("HomePage", () => {
|
||||
expect(screen.getByText("Loading overview...")).toBeInTheDocument();
|
||||
await waitFor(() => {
|
||||
expect(screen.getAllByText("Open sessions").length).toBeGreaterThan(0);
|
||||
expect(screen.getByText("Available projects")).toBeInTheDocument();
|
||||
expect(screen.getByText("Workspaces")).toBeInTheDocument();
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user