Use the correct waffle switch name for soft-blocking (#22852)

This commit is contained in:
William Durand 2024-11-14 10:48:58 +01:00 коммит произвёл GitHub
Родитель 67fd8a80ea
Коммит 27be5825ce
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: B5690EEEBB952194
2 изменённых файлов: 5 добавлений и 5 удалений

Просмотреть файл

@ -277,7 +277,7 @@ class MLBF:
'unblocked': blocked_removed,
}
if waffle.switch_is_active('mlbf-soft-blocks-enabled'):
if waffle.switch_is_active('enable-soft-blocking'):
soft_blocked_added, soft_blocked_removed, _ = diffs[BlockType.SOFT_BLOCKED]
stash_json['softblocked'] = soft_blocked_added
stash_json['unblocked'] = [

Просмотреть файл

@ -560,7 +560,7 @@ class TestMLBF(_MLBFBase):
'unblocked': [],
}
with override_switch('mlbf-soft-blocks-enabled', active=True):
with override_switch('enable-soft-blocking', active=True):
assert first_mlbf.generate_and_write_stash() == {
'blocked': [five_hash, six_hash],
'softblocked': [three_hash, four_hash],
@ -612,7 +612,7 @@ class TestMLBF(_MLBFBase):
'unblocked': [five_hash, six_hash],
}
with override_switch('mlbf-soft-blocks-enabled', active=True):
with override_switch('enable-soft-blocking', active=True):
assert second_mlbf.generate_and_write_stash(previous_mlbf=first_mlbf) == {
'blocked': [three_hash, two_hash],
'softblocked': [five_hash, one_hash],
@ -638,7 +638,7 @@ class TestMLBF(_MLBFBase):
'unblocked': [],
}
with override_switch('mlbf-soft-blocks-enabled', active=True):
with override_switch('enable-soft-blocking', active=True):
assert mlbf.generate_and_write_stash() == {
'blocked': MLBF.hash_filter_inputs(expected_blocked),
'softblocked': [],
@ -658,7 +658,7 @@ class TestMLBF(_MLBFBase):
'unblocked': MLBF.hash_filter_inputs(expected_unblocked),
}
with override_switch('mlbf-soft-blocks-enabled', active=True):
with override_switch('enable-soft-blocking', active=True):
assert next_mlbf.generate_and_write_stash(previous_mlbf=mlbf) == {
'blocked': [],
'softblocked': [],