This commit is contained in:
@@ -442,6 +442,20 @@ def test_marketplace_matcher_ignores_generic_variant_noise_for_peripera_brow_pen
|
||||
assert diagnostics.score < 0.76
|
||||
|
||||
|
||||
def test_marketplace_matcher_promotes_brandless_exact_identity_when_anchor_is_strong():
|
||||
from services.marketplace_product_matcher import score_marketplace_match
|
||||
|
||||
diagnostics = score_marketplace_match(
|
||||
"【小米有品】小浪智能感應自動噴香機(三種噴香模式 霧化噴香 芳香除臭)",
|
||||
"小浪智能感應自動噴香機 三種噴香模式 霧化噴香 芳香除臭 芳香劑 去異味",
|
||||
momo_price=539,
|
||||
competitor_price=539,
|
||||
)
|
||||
|
||||
assert diagnostics.score >= 0.76
|
||||
assert "brandless_exact_identity" in diagnostics.reasons
|
||||
|
||||
|
||||
def test_marketplace_matcher_rejects_same_count_different_unit_family():
|
||||
from services.marketplace_product_matcher import score_marketplace_match
|
||||
|
||||
|
||||
Reference in New Issue
Block a user