Exemple #1
0
def test_construct_alphabets4():
    outcomes = ['0', '1', '01']
    with pytest.raises(ditException):
        construct_alphabets(outcomes)
Exemple #2
0
def test_construct_alphabets2():
    outcomes = 3
    with pytest.raises(TypeError):
        construct_alphabets(outcomes)
Exemple #3
0
def test_construct_alphabets3():
    outcomes = [0, 1, 2]
    with pytest.raises(ditException):
        construct_alphabets(outcomes)
Exemple #4
0
def test_construct_alphabets1():
    outcomes = ['00', '01', '10', '11']
    alphas = construct_alphabets(outcomes)
    assert alphas == (('0', '1'), ('0', '1'))
Exemple #5
0
def test_construct_alphabets4():
    outcomes = ['0', '1', '01']
    with pytest.raises(ditException):
        construct_alphabets(outcomes)
Exemple #6
0
def test_construct_alphabets3():
    outcomes = [0, 1, 2]
    with pytest.raises(ditException):
        construct_alphabets(outcomes)
Exemple #7
0
def test_construct_alphabets2():
    outcomes = 3
    with pytest.raises(TypeError):
        construct_alphabets(outcomes)
Exemple #8
0
def test_construct_alphabets1():
    outcomes = ['00', '01', '10', '11']
    alphas = construct_alphabets(outcomes)
    assert alphas == (('0', '1'), ('0', '1'))