(CommandList children: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:test_description spids:[4]) op: Equal rhs: {(SQ <'diff --relative tests'>)} spids: [4] ) ] spids: [4] ) (C {(.)} {(./test-lib.sh)}) (C {(test_expect_success)} {(SQ <setup>)} { (SQ <'\n'> <'\tgit commit --allow-empty -m empty &&\n'> <'\techo content >file1 &&\n'> <'\tmkdir subdir &&\n'> <'\techo other content >subdir/file2 &&\n'> <'\tgit add . &&\n'> <'\tgit commit -m one\n'> ) } ) (FuncDef name: check_diff body: (BraceGroup children: [ (Sentence child: (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:expect spids:[37]) op: Equal rhs: {($ VSub_Number '$1')} spids: [37] ) ] spids: [37] ) terminator: <Op_Semi ';'> ) (C {(shift)}) (SimpleCommand words: [{(cat)}] redirects: [ (Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(expected)}) (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EOF)} here_end_span_id: 65 stdin_parts: [ ('diff --git a/') ($ VSub_Name '$expect') (' b/') ($ VSub_Name '$expect') ('\n') ('new file mode 100644\n') ('index 0000000..25c05ef\n') ('--- /dev/null\n') ('+++ b/') ($ VSub_Name '$expect') ('\n') ('@@ -0,0 +1 @@\n') ('+other content\n') ] ) ] ) (C {(test_expect_success)} {(DQ ('-p ') ($ VSub_Star '$*'))} { (DQ ('\n') ('\tgit diff -p ') ($ VSub_Star '$*') (' HEAD^ >actual &&\n') ('\ttest_cmp expected actual\n') ) } ) ] spids: [35] ) spids: [31 34] ) (FuncDef name: check_numstat body: (BraceGroup children: [ (Sentence child: (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:expect spids:[90]) op: Equal rhs: {($ VSub_Number '$1')} spids: [90] ) ] spids: [90] ) terminator: <Op_Semi ';'> ) (C {(shift)}) (SimpleCommand words: [{(cat)}] redirects: [ (Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(expected)}) (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EOF)} here_end_span_id: 108 stdin_parts: [('1\t0\t') ($ VSub_Name '$expect') ('\n')] ) ] ) (C {(test_expect_success)} {(DQ ('--numstat ') ($ VSub_Star '$*'))} { (DQ ('\n') ("\techo '1\t0\t") ($ VSub_Name '$expect') ("' >expected &&\n") ('\tgit diff --numstat ') ($ VSub_Star '$*') (' HEAD^ >actual &&\n') ('\ttest_cmp expected actual\n') ) } ) ] spids: [88] ) spids: [84 87] ) (FuncDef name: check_stat body: (BraceGroup children: [ (Sentence child: (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:expect spids:[136]) op: Equal rhs: {($ VSub_Number '$1')} spids: [136] ) ] spids: [136] ) terminator: <Op_Semi ';'> ) (C {(shift)}) (SimpleCommand words: [{(cat)}] redirects: [ (Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(expected)}) (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EOF)} here_end_span_id: 155 stdin_parts: [ (' ') ($ VSub_Name '$expect') (' | 1 +\n') (' 1 file changed, 1 insertion(+)\n') ] ) ] ) (C {(test_expect_success)} {(DQ ('--stat ') ($ VSub_Star '$*'))} { (DQ ('\n') ('\tgit diff --stat ') ($ VSub_Star '$*') (' HEAD^ >actual &&\n') ('\ttest_i18ncmp expected actual\n') ) } ) ] spids: [134] ) spids: [130 133] ) (FuncDef name: check_raw body: (BraceGroup children: [ (Sentence child: (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:expect spids:[180]) op: Equal rhs: {($ VSub_Number '$1')} spids: [180] ) ] spids: [180] ) terminator: <Op_Semi ';'> ) (C {(shift)}) (SimpleCommand words: [{(cat)}] redirects: [ (Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(expected)}) (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EOF)} here_end_span_id: 198 stdin_parts: [ ( ':000000 100644 0000000000000000000000000000000000000000 25c05ef3639d2d270e7fe765a67668f098092bc5 A\t' ) ($ VSub_Name '$expect') ('\n') ] ) ] ) (C {(test_expect_success)} {(DQ ('--raw ') ($ VSub_Star '$*'))} { (DQ ('\n') ('\tgit diff --no-abbrev --raw ') ($ VSub_Star '$*') (' HEAD^ >actual &&\n') ('\ttest_cmp expected actual\n') ) } ) ] spids: [178] ) spids: [174 177] ) (ForEach iter_name: type iter_words: [{(diff)} {(numstat)} {(stat)} {(raw)}] do_arg_iter: F body: (DoGroup children: [ (C {(check_) ($ VSub_Name '$type')} {(file2)} {(--relative) (Lit_Other '=') (subdir/)}) (C {(check_) ($ VSub_Name '$type')} {(file2)} {(--relative) (Lit_Other '=') (subdir)}) (C {(check_) ($ VSub_Name '$type')} {(dir/file2)} {(--relative) (Lit_Other '=') (sub)}) ] spids: [232 264] ) spids: [222 230] ) (C {(test_done)}) ] )