fix: TS 类型错误 — itIfInfra 签名 + logger 声明位置
All checks were successful
Deploy API Server / build-and-unit (push) Successful in 33s
Deploy API Server / current-integration (push) Successful in 29s
Deploy API Server / backward-compat (push) Successful in 0s
Deploy API Server / m-ai-03-synthetic-e2e (push) Successful in 14s
Deploy API Server / deploy (push) Successful in 1m1s
All checks were successful
Deploy API Server / build-and-unit (push) Successful in 33s
Deploy API Server / current-integration (push) Successful in 29s
Deploy API Server / backward-compat (push) Successful in 0s
Deploy API Server / m-ai-03-synthetic-e2e (push) Successful in 14s
Deploy API Server / deploy (push) Successful in 1m1s
- itIfInfra: () => Promise<void> → () => void | Promise<void>(兼容同步测试) - AiJobService.logger: 移至 class 顶部,消除方法调用前未声明问题 Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
d25c6161c4
commit
d0f75531ab
@ -8,6 +8,8 @@ import { JobNotCancellableError } from './ai-job.errors';
|
||||
|
||||
@Injectable()
|
||||
export class AiJobService {
|
||||
private readonly logger = new (require('@nestjs/common').Logger)(AiJobService.name);
|
||||
|
||||
constructor(
|
||||
private readonly prisma: PrismaService,
|
||||
private readonly lifecycleRepo: AiJobLifecycleRepository,
|
||||
@ -189,7 +191,6 @@ export class AiJobService {
|
||||
return this.toAdminResponse(newJob);
|
||||
}
|
||||
|
||||
private logger = new (require('@nestjs/common').Logger)(AiJobService.name);
|
||||
|
||||
// ── 可观测性 ──
|
||||
|
||||
|
||||
@ -97,7 +97,7 @@ describe('M-AI-03 Synthetic E2E (real infra)', () => {
|
||||
});
|
||||
|
||||
// Guard: skip all tests if infra not available
|
||||
const itIfInfra = (name: string, fn: () => Promise<void>) => {
|
||||
const itIfInfra = (name: string, fn: () => void | Promise<void>) => {
|
||||
it(name, async () => {
|
||||
if (!infraAvailable) {
|
||||
console.log(` [SKIP] Infra unavailable: ${name}`);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user