From b5b5c40fd7660abb5173fd0da1eb0be5a4cec1c5 Mon Sep 17 00:00:00 2001 From: Dan Sedano <47065799+thedandano@users.noreply.github.com> Date: Thu, 13 Aug 2026 13:15:52 -0700 Subject: [PATCH] Add xformers-only estimate test --- tests-unit/comfy_test/memory_required_test.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tests-unit/comfy_test/memory_required_test.py b/tests-unit/comfy_test/memory_required_test.py index 76e2d45a3..37ad8e498 100644 --- a/tests-unit/comfy_test/memory_required_test.py +++ b/tests-unit/comfy_test/memory_required_test.py @@ -43,6 +43,11 @@ def test_pytorch_flash_attention_uses_efficient_estimate(monkeypatch): assert _estimate() == EFFICIENT +def test_xformers_uses_efficient_estimate(monkeypatch): + _patch_attention(monkeypatch, xformers=True) + assert _estimate() == EFFICIENT + + def test_flash_attention_flag_uses_efficient_estimate(monkeypatch): # --use-flash-attention must select the efficient estimate even when # pytorch attention was not auto enabled (e.g. torch builds without