(CommandList
  children: [
    (Assignment
      keyword: Assign_None
      pairs: [
        (assign_pair
          lhs: (LhsName name:test_description)
          op: Equal
          rhs: {(SQ <"git p4 tests for excluded paths during clone and sync">)}
          spids: [4]
        )
      ]
      spids: [4]
    )
    (C {(.)} {(./lib-git-p4.sh)})
    (C {(test_expect_success)} {(SQ <"start p4d">)} {(SQ <"\n"> <"\tstart_p4d\n">)})
    (C {(test_expect_success)} {(SQ <"create exclude repo">)} 
      {
        (SQ <"\n"> <"\t(\n"> <"\t\tcd \"$cli\" &&\n"> <"\t\tmkdir -p wanted discard &&\n"> 
          <"\t\techo wanted >wanted/foo &&\n"> <"\t\techo discard >discard/foo &&\n"> <"\t\tp4 add wanted/foo discard/foo &&\n"> 
          <"\t\tp4 submit -d \"initial revision\"\n"> <"\t)\n">
        )
      }
    )
    (C {(test_expect_success)} {(SQ <"check the repo was created correctly">)} 
      {
        (SQ <"\n"> <"\ttest_when_finished cleanup_git &&\n"> 
          <"\tgit p4 clone --dest=\"$git\" //depot/...@all &&\n"> <"\t(\n"> <"\t\tcd \"$git\" &&\n"> <"\t\ttest_path_is_file wanted/foo &&\n"> 
          <"\t\ttest_path_is_file discard/foo\n"> <"\t)\n">
        )
      }
    )
    (C {(test_expect_success)} {(SQ <"clone, excluding part of repo">)} 
      {
        (SQ <"\n"> <"\ttest_when_finished cleanup_git &&\n"> 
          <"\tgit p4 clone -//depot/discard/... --dest=\"$git\" //depot/...@all &&\n"> <"\t(\n"> <"\t\tcd \"$git\" &&\n"> <"\t\ttest_path_is_file wanted/foo &&\n"> 
          <"\t\ttest_path_is_missing discard/foo\n"> <"\t)\n">
        )
      }
    )
    (C {(test_expect_success)} {(SQ <"clone, then sync with exclude">)} 
      {
        (SQ <"\n"> <"\ttest_when_finished cleanup_git &&\n"> 
          <"\tgit p4 clone -//depot/discard/... --dest=\"$git\" //depot/...@all &&\n"> <"\t(\n"> <"\t\tcd \"$cli\" &&\n"> <"\t\tp4 edit wanted/foo discard/foo &&\n"> 
          <"\t\tdate >>wanted/foo &&\n"> <"\t\tdate >>discard/foo &&\n"> <"\t\tp4 submit -d \"updating\" &&\n"> <"\n"> <"\t\tcd \"$git\" &&\n"> 
          <"\t\tgit p4 sync -//depot/discard/... &&\n"> <"\t\ttest_path_is_file wanted/foo &&\n"> <"\t\ttest_path_is_missing discard/foo\n"> <"\t)\n">
        )
      }
    )
    (C {(test_expect_success)} {(SQ <"kill p4d">)} {(SQ <"\n"> <"\tkill_p4d\n">)})
    (C {(test_done)})
  ]
)