refactor(decnet_web/AttackerDetail): trim shell + bump coverage floor
Drop unused icon/api/useEffect/Tag imports left behind by the fingerprint, behaviour, and IntelPanel extractions. AttackerDetail.tsx ends at 450 LOC across Phase 10 (down from 1652 / 73% reduction). Coverage floor: lines 23->24, functions 20->21, branches 17->19, statements 22->23.
This commit is contained in:
@@ -1,7 +1,8 @@
|
||||
import React, { useEffect, useState } from 'react';
|
||||
import React, { useState } from 'react';
|
||||
import { useParams, useNavigate } from 'react-router-dom';
|
||||
import { Activity, AlertTriangle, ArrowLeft, Cpu, Crosshair, Eye, Fingerprint, Globe, Keyboard, Shield, Clock, Sparkles, Wifi, Lock, FileKey, Radio, Timer, FileText, AtSign } from '../icons';
|
||||
import api from '../utils/api';
|
||||
import {
|
||||
Activity, ArrowLeft, Crosshair, Fingerprint, Globe, FileText, AtSign,
|
||||
} from '../icons';
|
||||
import SessionDrawer from './SessionDrawer';
|
||||
import EmptyState from './EmptyState/EmptyState';
|
||||
import TTPsObservedSection from './TTPsObservedSection';
|
||||
@@ -13,7 +14,7 @@ import { ServicesTargeted } from './AttackerDetail/sections/ServicesTargeted';
|
||||
import { CommandsViewer } from './AttackerDetail/sections/CommandsViewer';
|
||||
import { ArtifactsPanel } from './AttackerDetail/sections/ArtifactsPanel';
|
||||
import { MailLogPanel } from './AttackerDetail/sections/MailLogPanel';
|
||||
import { Tag, Section } from './AttackerDetail/ui';
|
||||
import { Section } from './AttackerDetail/ui';
|
||||
import {
|
||||
FingerprintGroup, getPayload,
|
||||
} from './AttackerDetail/fingerprints';
|
||||
|
||||
@@ -15,15 +15,16 @@ export default defineConfig({
|
||||
include: ['src/**/*.{ts,tsx}'],
|
||||
exclude: ['src/**/*.d.ts', 'src/test/**', 'src/main.tsx'],
|
||||
// Baseline floors. Each refactor PR raises these; never lower.
|
||||
// Phase 9 (Credentials trim): page shell down from 487 to 231 LOC.
|
||||
// Lifted helpers, SortTh, CredsTable, ReuseTable, and a useCredentials
|
||||
// hook (3 endpoints + reuse-map). 13 new tests. Suite: 48 files,
|
||||
// 236 tests, 24.16% lines / 17.72% branches.
|
||||
// Phase 10 (AttackerDetail follow-through): page shell down from
|
||||
// 1652 to 450 LOC. Lifted fingerprint renderers (12), behaviour
|
||||
// panel (8 sub-pieces + lookups), and IntelPanel into focused
|
||||
// sub-modules. 13 new tests. Suite: 50 files, 249 tests,
|
||||
// 24.8% lines / 19.53% branches.
|
||||
thresholds: {
|
||||
lines: 23,
|
||||
functions: 20,
|
||||
branches: 17,
|
||||
statements: 22,
|
||||
lines: 24,
|
||||
functions: 21,
|
||||
branches: 19,
|
||||
statements: 23,
|
||||
},
|
||||
},
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user