Ejemplo n.º 1
0
def test_lookup(lookup_value, result1, result2):
    assert result1 == lookup(lookup_value, lookup_vector)
    assert result1 == lookup(lookup_value, tuple(zip(*lookup_vector)))
    assert result2 == lookup(lookup_value, lookup_vector, lookup_result)
    assert result2 == lookup(lookup_value, tuple(zip(*lookup_vector)),
                             tuple(zip(*lookup_result)))
    assert result2 == lookup(lookup_value, lookup_rows)
    assert result2 == lookup(lookup_value, lookup_columns)
Ejemplo n.º 2
0
def test_lookup(lookup_value, result1, result2):
    assert result1 == lookup(lookup_value, lookup_vector)
    assert result1 == lookup(lookup_value, tuple(zip(*lookup_vector)))
    assert result2 == lookup(lookup_value, lookup_vector, lookup_result)
    assert result2 == lookup(lookup_value, tuple(zip(*lookup_vector)),
                             tuple(zip(*lookup_result)))
    assert result2 == lookup(lookup_value, lookup_rows)
    assert result2 == lookup(lookup_value, lookup_columns)
Ejemplo n.º 3
0
def test_lookup_error():
    assert NA_ERROR == lookup(1, 1)
Ejemplo n.º 4
0
def test_lookup_error():
    assert NA_ERROR == lookup(1, 1)