Ejemplo n.º 1
0
def test_dataloadingconfig():
    dlc = task.DataLoadingConfig(
        "s3://input/path", "s3://output/path", True, task.DataLoadingConfig.LITERALMAP_FORMAT_YAML,
    )
    dlc2 = task.DataLoadingConfig.from_flyte_idl(dlc.to_flyte_idl())
    assert dlc2 == dlc

    dlc = task.DataLoadingConfig(
        "s3://input/path",
        "s3://output/path",
        True,
        task.DataLoadingConfig.LITERALMAP_FORMAT_YAML,
        io_strategy=task.IOStrategy(),
    )
    dlc2 = task.DataLoadingConfig.from_flyte_idl(dlc.to_flyte_idl())
    assert dlc2 == dlc
Ejemplo n.º 2
0
def test_ioconfig():
    io = task.IOStrategy(task.IOStrategy.DOWNLOAD_MODE_NO_DOWNLOAD, task.IOStrategy.UPLOAD_MODE_NO_UPLOAD)
    assert io == task.IOStrategy.from_flyte_idl(io.to_flyte_idl())