Beispiel #1
0
def test_python_object_dagster_type():
    from docs_snippets.concepts.types.object_type import EvenType, double_even

    assert execute_solid(double_even, input_values={
        "even_num": EvenType(2)
    }).success
    with pytest.raises(AssertionError):
        execute_solid(double_even, input_values={"even_num": EvenType(3)})
Beispiel #2
0
def test_make_python_type_usable_as_dagster_type():
    from docs_snippets.concepts.types.make_usable import EvenType, double_even

    double_even(even_num=EvenType(2))
Beispiel #3
0
def test_usable_as_dagster_type():
    from docs_snippets.concepts.types.usable_as import EvenType, double_even

    double_even(even_num=EvenType(2))
Beispiel #4
0
def test_python_object_dagster_type():
    from docs_snippets.concepts.types.object_type import EvenType, double_even

    double_even(even_num=EvenType(2))
    with pytest.raises(AssertionError):
        double_even(even_num=EvenType(3))
Beispiel #5
0
def test_make_python_type_usable_as_dagster_type():
    from docs_snippets.concepts.types.make_usable import EvenType, double_even

    assert execute_solid(double_even, input_values={
        "even_num": EvenType(2)
    }).success