Exemplo n.º 1
0
def test_action_match_negate():
    action = Action(r'(\w+) \w+', negate=True)
    groups = action._match('test case')
    assert groups is None
    groups = action._match('test')
    assert groups == ()
Exemplo n.º 2
0
def test_action_match_negate():
    action = Action(r'(\w+) \w+', negate=True)
    groups = action._match('test case')
    assert groups is None
    groups = action._match('test')
    assert groups == ()
Exemplo n.º 3
0
def test_action_match():
    action = Action(r'(\w+) \w+')
    groups = action._match('test case')
    assert groups == ('test',)
Exemplo n.º 4
0
def test_action_match():
    action = Action(r'(\w+) \w+')
    groups = action._match('test case')
    assert groups == ('test', )