feat(tests): containment_result field on blue team evaluation
Aegis CI / lint-and-test (push) Has been cancelled
Snyk Security Scan / Python vulnerabilities (backend) (push) Has been cancelled
Snyk Security Scan / npm vulnerabilities (frontend) (push) Has been cancelled
Snyk Security Scan / Docker image vulnerabilities (backend) (push) Has been cancelled
Aegis CI / lint-and-test (push) Has been cancelled
Snyk Security Scan / Python vulnerabilities (backend) (push) Has been cancelled
Snyk Security Scan / npm vulnerabilities (frontend) (push) Has been cancelled
Snyk Security Scan / Docker image vulnerabilities (backend) (push) Has been cancelled
This commit is contained in:
@@ -24,7 +24,7 @@ import {
|
||||
} from "../api/tests";
|
||||
import { uploadEvidence, getEvidence } from "../api/evidence";
|
||||
import { useAuth } from "../context/AuthContext";
|
||||
import type { TestResult, TeamSide, TestTimelineEntry } from "../types/models";
|
||||
import type { TestResult, ContainmentResult, TeamSide, TestTimelineEntry } from "../types/models";
|
||||
|
||||
import TestDetailHeader from "../components/test-detail/TestDetailHeader";
|
||||
import TeamTabs from "../components/test-detail/TeamTabs";
|
||||
@@ -62,9 +62,11 @@ export default function TestDetailPage() {
|
||||
|
||||
const [blueDraft, setBlueDraft] = useState<{
|
||||
detection_result: TestResult | "";
|
||||
containment_result: ContainmentResult | "";
|
||||
blue_summary: string;
|
||||
}>({
|
||||
detection_result: "",
|
||||
containment_result: "",
|
||||
blue_summary: "",
|
||||
});
|
||||
|
||||
@@ -109,6 +111,7 @@ export default function TestDetailPage() {
|
||||
});
|
||||
setBlueDraft({
|
||||
detection_result: test.detection_result || "",
|
||||
containment_result: test.containment_result || "",
|
||||
blue_summary: test.blue_summary || "",
|
||||
});
|
||||
}
|
||||
@@ -161,6 +164,7 @@ export default function TestDetailPage() {
|
||||
mutationFn: () =>
|
||||
updateTestBlue(testId!, {
|
||||
detection_result: (blueDraft.detection_result as TestResult) || undefined,
|
||||
containment_result: (blueDraft.containment_result as ContainmentResult) || undefined,
|
||||
blue_summary: blueDraft.blue_summary || undefined,
|
||||
}),
|
||||
onSuccess: () => {
|
||||
|
||||
Reference in New Issue
Block a user