#102 Add support of rules with side effects

This commit is contained in:
nvbn
2015-05-01 04:39:37 +02:00
parent b928a59672
commit b985dfbffc
6 changed files with 49 additions and 21 deletions
+4 -3
View File
@@ -1,11 +1,12 @@
from thefuck.types import Rule, RulesNamesList, Settings
from thefuck.types import RulesNamesList, Settings
from tests.utils import Rule
def test_rules_names_list():
assert RulesNamesList(['bash', 'lisp']) == ['bash', 'lisp']
assert RulesNamesList(['bash', 'lisp']) == RulesNamesList(['bash', 'lisp'])
assert Rule('lisp', None, None, False) in RulesNamesList(['lisp'])
assert Rule('bash', None, None, False) not in RulesNamesList(['lisp'])
assert Rule('lisp') in RulesNamesList(['lisp'])
assert Rule('bash') not in RulesNamesList(['lisp'])
def test_update_settings():