Exemplo n.º 1
0
def test_unsupported_mixin_comparison_conditions(op, typedef):
    class Model(BaseModel):
        id = Column(Integer, hash_key=True)

    column = Column(typedef, dynamo_name="d")
    column.model = Model
    column._name = "c"
    with pytest.raises(InvalidCondition):
        op(column, "value")
Exemplo n.º 2
0
def test_unsupported_mixin_function_conditions(op, typedefs, args):
    class Model(BaseModel):
        id = Column(Integer, hash_key=True)

    for typedef in typedefs:
        column = Column(typedef, dynamo_name="d")
        column.model = Model
        column._name = "c"
        with pytest.raises(InvalidCondition):
            getattr(column, op)(*args)
            column.begins_with(object())