[CI][Bugfix] Fix MoE reprocess test mock after #57405's kernel refactor (#57641)
Signed-off-by: kimi-no-na-wa <kimi-no-na-wa@users.noreply.github.com> Signed-off-by: Wentao Ye <44945378+yewentao256@users.noreply.github.com> Co-authored-by: kimi-no-na-wa <kimi-no-na-wa@users.noreply.github.com> Co-authored-by: Wentao Ye <44945378+yewentao256@users.noreply.github.com>
vllm-agent committed
Sep 19, 2026 at 14:42 UTC
674b6d95d6d0bd63b44cae0abe2bf304328c73e9
1 file changed
+3
-1
tests/kernels/moe/test_flashinfer.py
+3
-1
@@ -2,6 +2,7 @@
2
# SPDX-FileCopyrightText: Copyright contributors to the vLLM project
3
import multiprocessing
4
from dataclasses import dataclass
5
+from unittest.mock import MagicMock
6
7
import pytest
8
import torch
@@ -537,10 +538,11 @@ def _make_unquantized_flashinfer_test_layer(
538
method.moe = moe_config
539
method.unquantized_backend = UnquantizedMoeBackend.FLASHINFER_TRTLLM
540
method.moe_kernel = None
541
+ mock_kernel = MagicMock()
542
monkeypatch.setattr(
543
method,
544
"_init_moe_kernel",
543
- lambda _: setattr(method, "moe_kernel", object()),
545
+ lambda _: setattr(method, "moe_kernel", mock_kernel),
546
)
547
548
layer = torch.nn.Module()