def METHOD_NAME(tmpdir, yaml_file):
    f: Flow = Flow.load_config(yaml_file)
    # assert vars inside `with`
    assert f._kwargs['name'] == 'abc'
    assert f.port == 12345
    assert f.protocol == ProtocolType.HTTP
    # assert executor args
    assert f._deployment_nodes['custom1'].args.uses == 'jinahub://CustomExecutor1'
    assert f._deployment_nodes['custom2'].args.uses == 'CustomExecutor2'
    assert f._deployment_nodes['custom2'].args.port == [23456]
    # change args inside the gateway configuration
    f.port = 12346
    f.protocol = ProtocolType.WEBSOCKET
    # change executor args
    f._deployment_nodes['custom2'].args.port = 23457
    f.save_config(str(Path(tmpdir) / 'a0.yml'))
    f1: Flow = Flow.load_config(str(Path(tmpdir) / 'a0.yml'))
    # assert args from original yaml
    assert f1._kwargs['name'] == 'abc'
    assert 'custom1' in f1._deployment_nodes
    assert 'custom2' in f1._deployment_nodes
    assert f1._deployment_nodes['custom1'].args.uses == 'jinahub://CustomExecutor1'
    assert f1._deployment_nodes['custom2'].args.uses == 'CustomExecutor2'
    # assert args modified in code
    assert f1.port == 12346
    assert f1.protocol == ProtocolType.WEBSOCKET
    assert f1._deployment_nodes['custom2'].args.port == [23457]