// Given the dependency file contains nested dependencies and the command was
//     run without recursion
// When the command is run with recursion
// Then the nested dependencies are pulled to the correct locations with the
//     correct contents
Given the dependency file contains nested dependencies and the command was
run without recursion
When the command is run with recursion
Then the nested dependencies are pulled to the correct locations with the
correct contents
Given the dependency file contains nested dependencies and the command was run without recursion When the command is run with recursion Then the nested dependencies are pulled to the correct locations with the correct contents
fn run_with_recursion_after_run_without_recursion() {
    let test_name = "run_with_recursion_after_run_without_recursion";
    let Layout{deps_file_conts, dep_srcs_dir, proj_dir, ..} =
        check_nested_deps_not_pulled_without_recursion(test_name);
    let cmd_result = test_setup::with_git_server(
        dep_srcs_dir,
        || {
            let mut cmd = test_setup::new_test_cmd(proj_dir.clone());
            cmd.arg("--recursive");
            cmd.assert()
        },
    );
    cmd_result.code(0).stdout("").stderr("");
    fs_check::assert_contents(
        &proj_dir,
        &Node::Dir(hashmap!{
            "dpnd.txt" => Node::File(&deps_file_conts),
            "deps" => Node::Dir(hashmap!{
                "current_dpnd.txt" => Node::AnyFile,
                "all_scripts" => Node::Dir(hashmap!{
                    ".git" => Node::AnyDir,
                    "dpnd.txt" => Node::AnyFile,
                    "script.sh" => Node::File("echo 'hello, all!'"),
                    "deps" => Node::Dir(hashmap!{
                        "current_dpnd.txt" => Node::AnyFile,
                        "my_scripts" => Node::Dir(hashmap!{
                            ".git" => Node::AnyDir,
                            "script.sh" => Node::File("echo 'hello, world!'"),
                        }),
                        "your_scripts" => Node::Dir(hashmap!{
                            ".git" => Node::AnyDir,
                            "script.sh" => Node::File("echo 'hello, sun!'"),
                        }),
                    }),
                }),
            }),
        }),
    );
}
fn run_with_recursion_after_run_without_recursion ( ) { let test_name = " " ; let Layout { deps_file_conts , dep_srcs_dir , proj_dir , .. } = check_nested_deps_not_pulled_without_recursion ( test_name ) ; let cmd_result = test_setup :: with_git_server ( dep_srcs_dir , | | { let mut cmd = test_setup :: new_test_cmd ( proj_dir . clone ( ) ) ; cmd . arg ( " " ) ; cmd . assert ( ) } , ) ; cmd_result . code ( 0 ) . stdout ( " " ) . stderr ( " " ) ; fs_check :: assert_contents ( & proj_dir , & Node :: Dir ( hashmap ! { " " Node File ( deps_file_conts ) " " Node Dir ( hashmap { " " Node AnyFile " " Node Dir ( hashmap { " " Node AnyDir " " Node AnyFile " " Node File ( " " ) " " Node Dir ( hashmap { " " Node AnyFile " " Node Dir ( hashmap { " " Node AnyDir " " Node File ( " " ) } ) " " Node Dir ( hashmap { " " Node AnyDir " " Node File ( " " ) } ) } ) } ) } ) } ) , ) ; }
Given the dependency file contains nested dependencies and the command was
run without recursion
When the command is run with recursion
Then the nested dependencies are pulled to the correct locations with the
correct contents
Given the dependency file contains nested dependencies and the command was run without recursion When the command is run with recursion Then the nested dependencies are pulled to the correct locations with the correct contents