(command.CommandList
  children: [
    (command.Assignment
      keyword: Assign_None
      pairs: [
        (assign_pair
          lhs: (lhs_expr.LhsName name:test_description)
          op: Equal
          rhs: {(SQ <'git update-index --again test.\n'>)}
        )
      ]
    )
    (C {(.)} {(./test-lib.sh)})
    (command.SimpleCommand
      words: [{(cat)}]
      redirects: [
        (redir.Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(expected)})
        (redir.HereDoc
          op: <Redir_DLess '<<'>
          fd: 16777215
          here_begin: {(word_part.EscapedLiteralPart token:<Lit_EscapedChar '\\E'>) (OF)}
          here_end_span_id: 36
          stdin_parts: [
            ('100644 3b18e512dba79e4c8300dd08aeb37f8e728b8dad 0\tfile1\n')
            ('100644 9db8893856a8a02eaa73470054b7c1c5a7c82e47 0\tfile2\n')
          ]
        )
      ]
    )
    (C {(test_expect_success)} {(SQ <'update-index --add'>)} 
      {
        (SQ <'echo hello world >file1 &&\n'> <'\t echo goodbye people >file2 &&\n'> 
          <'\t git update-index --add file1 file2 &&\n'> <'\t git ls-files -s >current &&\n'> <'\t cmp current expected'>
        )
      }
    )
    (C {(test_expect_success)} {(SQ <'update-index --again'>)} 
      {
        (SQ <'rm -f file1 &&\n'> <'\techo hello everybody >file2 &&\n'> 
          <'\tif git update-index --again\n'> <'\tthen\n'> <'\t\techo should have refused to remove file1\n'> <'\t\texit 1\n'> <'\telse\n'> 
          <'\t\techo happy - failed as expected\n'> <'\tfi &&\n'> <'\t git ls-files -s >current &&\n'> <'\t cmp current expected'>
        )
      }
    )
    (command.SimpleCommand
      words: [{(cat)}]
      redirects: [
        (redir.Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(expected)})
        (redir.HereDoc
          op: <Redir_DLess '<<'>
          fd: 16777215
          here_begin: {(word_part.EscapedLiteralPart token:<Lit_EscapedChar '\\E'>) (OF)}
          here_end_span_id: 88
          stdin_parts: [('100644 0f1ae1422c2bf43f117d3dbd715c988a9ed2103f 0\tfile2\n')]
        )
      ]
    )
    (C {(test_expect_success)} {(SQ <'update-index --remove --again'>)} 
      {
        (SQ <'git update-index --remove --again &&\n'> <'\t git ls-files -s >current &&\n'> 
          <'\t cmp current expected'>
        )
      }
    )
    (C {(test_expect_success)} {(SQ <'first commit'>)} {(SQ <'git commit -m initial'>)})
    (command.SimpleCommand
      words: [{(cat)}]
      redirects: [
        (redir.Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(expected)})
        (redir.HereDoc
          op: <Redir_DLess '<<'>
          fd: 16777215
          here_begin: {(word_part.EscapedLiteralPart token:<Lit_EscapedChar '\\E'>) (OF)}
          here_end_span_id: 127
          stdin_parts: [
            ('100644 53ab446c3f4e42ce9bb728a0ccb283a101be4979 0\tdir1/file3\n')
            ('100644 0f1ae1422c2bf43f117d3dbd715c988a9ed2103f 0\tfile2\n')
          ]
        )
      ]
    )
    (C {(test_expect_success)} {(SQ <'update-index again'>)} 
      {
        (SQ <'mkdir -p dir1 &&\n'> <'\techo hello world >dir1/file3 &&\n'> 
          <'\techo goodbye people >file2 &&\n'> <'\tgit update-index --add file2 dir1/file3 &&\n'> <'\techo hello everybody >file2 &&\n'> 
          <'\techo happy >dir1/file3 &&\n'> <'\tgit update-index --again &&\n'> <'\tgit ls-files -s >current &&\n'> <'\tcmp current expected'>
        )
      }
    )
    (command.SimpleCommand
      words: [{(cat)}]
      redirects: [
        (redir.Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(expected)})
        (redir.HereDoc
          op: <Redir_DLess '<<'>
          fd: 16777215
          here_begin: {(word_part.EscapedLiteralPart token:<Lit_EscapedChar '\\E'>) (OF)}
          here_end_span_id: 161
          stdin_parts: [
            ('100644 d7fb3f695f06c759dbf3ab00046e7cc2da22d10f 0\tdir1/file3\n')
            ('100644 0f1ae1422c2bf43f117d3dbd715c988a9ed2103f 0\tfile2\n')
          ]
        )
      ]
    )
    (C {(test_expect_success)} {(SQ <'update-index --update from subdir'>)} 
      {
        (SQ <'echo not so happy >file2 &&\n'> <'\t(cd dir1 &&\n'> <'\tcat ../file2 >file3 &&\n'> 
          <'\tgit update-index --again\n'> <'\t) &&\n'> <'\tgit ls-files -s >current &&\n'> <'\tcmp current expected'>
        )
      }
    )
    (command.SimpleCommand
      words: [{(cat)}]
      redirects: [
        (redir.Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(expected)})
        (redir.HereDoc
          op: <Redir_DLess '<<'>
          fd: 16777215
          here_begin: {(word_part.EscapedLiteralPart token:<Lit_EscapedChar '\\E'>) (OF)}
          here_end_span_id: 193
          stdin_parts: [
            ('100644 594fb5bb1759d90998e2bf2a38261ae8e243c760 0\tdir1/file3\n')
            ('100644 0f1ae1422c2bf43f117d3dbd715c988a9ed2103f 0\tfile2\n')
          ]
        )
      ]
    )
    (C {(test_expect_success)} {(SQ <'update-index --update with pathspec'>)} 
      {
        (SQ <'echo very happy >file2 &&\n'> <'\tcat file2 >dir1/file3 &&\n'> 
          <'\tgit update-index --again dir1/ &&\n'> <'\tgit ls-files -s >current &&\n'> <'\tcmp current expected'>
        )
      }
    )
    (C {(test_done)})
  ]
)