(command.CommandList
  children: [
    (command.ShAssignment
      left: <Id.Lit_VarLike 'i='>
      pairs: [
        (AssignPair
          left: <Id.Lit_VarLike 'i='>
          lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'i='> name:i)
          op: assign_op.Equal
          rhs: {<1>}
        )
      ]
      redirects: []
    )
    (command.Pipeline
      children: [
        (command.Simple
          blame_tok: <Id.Left_DoubleQuote '"'>
          more_env: []
          words: [
            {
              (DQ 
                (CommandSub
                  left_token: <Id.Left_DollarParen '$('>
                  child: 
                    (command.Simple
                      blame_tok: <dirname>
                      more_env: []
                      words: [{<dirname>} {($ Id.VSub_Number 0)}]
                      redirects: []
                      do_fork: T
                    )
                  right: <Id.Eof_RParen _>
                ) <'/kqtest'>
              )
            }
          ]
          redirects: []
          do_fork: T
        )
        (command.WhileUntil
          keyword: <Id.KW_While while>
          cond: 
            (condition.Shell
              commands: [
                (command.Sentence
                  child: 
                    (command.Simple
                      blame_tok: <read>
                      more_env: []
                      words: [{<read>} {<line>}]
                      redirects: []
                      do_fork: T
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
          body: 
            (command.DoGroup
              left: <Id.KW_Do do>
              children: [
                (command.Pipeline
                  children: [
                    (command.Simple
                      blame_tok: <echo>
                      more_env: []
                      words: [{<echo>} {($ Id.VSub_DollarName line)}]
                      redirects: []
                      do_fork: T
                    )
                    (command.Simple
                      blame_tok: <grep>
                      more_env: []
                      words: [{<grep>} {<-q>} {<passed>}]
                      redirects: []
                      do_fork: T
                    )
                  ]
                  ops: [<Id.Op_Pipe _>]
                )
                (command.If
                  if_kw: <Id.KW_If if>
                  arms: [
                    (IfArm
                      keyword: <Id.KW_If if>
                      cond: 
                        (condition.Shell
                          commands: [
                            (command.Sentence
                              child: 
                                (command.Simple
                                  blame_tok: <Id.Lit_LBracket '['>
                                  more_env: []
                                  words: [
                                    {<Id.Lit_LBracket '['>}
                                    {($ Id.VSub_QMark '?')}
                                    {<-eq>}
                                    {<0>}
                                    {<Id.Lit_RBracket ']'>}
                                  ]
                                  redirects: []
                                  do_fork: T
                                )
                              terminator: <Id.Op_Semi _>
                            )
                          ]
                        )
                      then_kw: <Id.KW_Then then>
                      action: [
                        (command.Simple
                          blame_tok: <echo>
                          more_env: []
                          words: [
                            {<echo>}
                            {
                              (DQ <'ok - '> ($ Id.VSub_DollarName i) <' '> ($ Id.VSub_DollarName line))
                            }
                          ]
                          redirects: []
                          do_fork: T
                        )
                        (command.Simple
                          blame_tok: <Id.Lit_Colon ':'>
                          more_env: []
                          words: [
                            {<Id.Lit_Colon ':'>}
                            {
                              (word_part.ArithSub
                                left: <Id.Left_DollarDParen '$(('>
                                anode: 
                                  (arith_expr.BinaryAssign
                                    op_id: Id.Arith_PlusEqual
                                    left: ($ Id.Lit_ArithVarLike i)
                                    right: {<Id.Lit_Digits 1>}
                                  )
                                right: <Id.Right_DollarDParen _>
                              )
                            }
                          ]
                          redirects: []
                          do_fork: T
                        )
                      ]
                      spids: [44 57]
                    )
                  ]
                  else_action: []
                  fi_kw: <Id.KW_Fi fi>
                  redirects: []
                )
                (command.Pipeline
                  children: [
                    (command.Simple
                      blame_tok: <echo>
                      more_env: []
                      words: [{<echo>} {($ Id.VSub_DollarName line)}]
                      redirects: []
                      do_fork: T
                    )
                    (command.Simple
                      blame_tok: <grep>
                      more_env: []
                      words: [{<grep>} {<-q>} {(SQ <'tests completed'>)}]
                      redirects: []
                      do_fork: T
                    )
                  ]
                  ops: [<Id.Op_Pipe _>]
                )
                (command.If
                  if_kw: <Id.KW_If if>
                  arms: [
                    (IfArm
                      keyword: <Id.KW_If if>
                      cond: 
                        (condition.Shell
                          commands: [
                            (command.Sentence
                              child: 
                                (command.Simple
                                  blame_tok: <Id.Lit_LBracket '['>
                                  more_env: []
                                  words: [
                                    {<Id.Lit_LBracket '['>}
                                    {($ Id.VSub_QMark '?')}
                                    {<-eq>}
                                    {<0>}
                                    {<Id.Lit_RBracket ']'>}
                                  ]
                                  redirects: []
                                  do_fork: T
                                )
                              terminator: <Id.Op_Semi _>
                            )
                          ]
                        )
                      then_kw: <Id.KW_Then then>
                      action: [
                        (command.Simple
                          blame_tok: <echo>
                          more_env: []
                          words: [{<echo>} {<-n>} {(DQ <1..>)}]
                          redirects: []
                          do_fork: T
                        )
                        (command.Pipeline
                          children: [
                            (command.Simple
                              blame_tok: <echo>
                              more_env: []
                              words: [{<echo>} {($ Id.VSub_DollarName line)}]
                              redirects: []
                              do_fork: T
                            )
                            (command.Simple
                              blame_tok: <cut>
                              more_env: []
                              words: [{<cut>} {<-d> (SQ <' '>)} {<-f3>}]
                              redirects: []
                              do_fork: T
                            )
                          ]
                          ops: [<Id.Op_Pipe _>]
                        )
                      ]
                      spids: [103 116]
                    )
                  ]
                  else_action: []
                  fi_kw: <Id.KW_Fi fi>
                  redirects: []
                )
              ]
              right: <Id.KW_Done done>
            )
          redirects: []
        )
      ]
      ops: [<Id.Op_Pipe _>]
    )
  ]
)