git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH 4/7] cvsserver: Add a few tests for 'status' command

From
Damien Diederen <dash@foobox.net>
Date
Mar 24, 2008, 22:50 UTC
Message-ID
<96f67c3e4ad8f5fe0c179b97b9f1ae1a7943b106.1206393086.git.dash@foobox.net>
In-Reply-To
<cover.1206393086.git.dash@foobox.net>
Signed-off-by: Damien Diederen <dash@foobox.net>
---
 t/t9400-git-cvsserver-server.sh |   32 ++++++++++++++++++++++++++++++++
 1 files changed, 32 insertions(+), 0 deletions(-)
diff --git a/t/t9400-git-cvsserver-server.sh b/t/t9400-git-cvsserver-server.sh
index b91b151..6168324 100755
--- a/t/t9400-git-cvsserver-server.sh
+++ b/t/t9400-git-cvsserver-server.sh
@@ -420,4 +420,36 @@ test_expect_success 'cvs update (merge no-op)' \
     GIT_CONFIG="$git_config" cvs -Q update &&
     diff -q merge ../merge'
 
+#------------
+# CVS STATUS
+#------------
+
+cd "$WORKDIR"
+test_expect_success 'cvs status' '
+    mkdir status.dir &&
+    echo Line > status.dir/status.file &&
+    echo Line > status.file &&
+    git add status.dir status.file &&
+    git commit -q -m "Status test" &&
+    git push gitcvs.git >/dev/null &&
+    cd cvswork &&
+    GIT_CONFIG="$git_config" cvs update &&
+    GIT_CONFIG="$git_config" cvs status | grep "^File: status.file" >../out &&
+    test $(wc -l <../out) = 2
+'
+
+cd "$WORKDIR"
+test_expect_success 'cvs status (nonrecursive)' '
+    cd cvswork &&
+    GIT_CONFIG="$git_config" cvs status -l | grep "^File: status.file" >../out &&
+    test $(wc -l <../out) = 1
+'
+
+cd "$WORKDIR"
+test_expect_success 'cvs status (no subdirs in header)' '
+    cd cvswork &&
+    GIT_CONFIG="$git_config" cvs status | grep ^File: >../out &&
+    ! grep / <../out
+'
+
 test_done
-- 
1.5.5.rc1.6.gd183
Previous: Damien DiederenNext: Damien Diederen
Message 6 of 22 in “Enhance TkCVS interoperability”
  1. 0/7 Enhance TkCVS interoperabilityDamien Diederen, Mar 24, 2008
  2. 1/7 cvsserver: Respond to the 'editors' commandDamien Diederen, Mar 24, 2008
  3. Frank LichtenheldMar 25, 2008
  4. 2/7 cvsserver: Only print the file part of the filename in status headerDamien Diederen, Mar 24, 2008
  5. 3/7 cvsserver: Do not include status output for subdirectories if -l is passedDamien Diederen, Mar 24, 2008
  6. 4/7 cvsserver: Add a few tests for 'status' commandDamien Diederen, Mar 24, 2008
  7. 5/7 cvsserver: Implemented update -p (print to stdout)Damien Diederen, Mar 24, 2008
  8. 6/7 cvsserver: Added test for update -pDamien Diederen, Mar 24, 2008
  9. 7/7 cvsserver: Use the user part of the email in log and annotate resultsDamien Diederen, Mar 24, 2008
  10. Frank LichtenheldMar 25, 2008
  11. Rafael Garcia-SuarezMar 25, 2008
  12. Damien DiederenMar 25, 2008
  13. Junio C HamanoMar 25, 2008
  14. 0/7 Enhance TkCVS interoperabilityDamien Diederen, Mar 27, 2008
  15. Junio C HamanoMar 28, 2008
  16. 1/7 cvsserver: Respond to the 'editors' and 'watchers' commandsDamien Diederen, Mar 27, 2008
  17. 2/7 cvsserver: Only print the file part of the filename in status headerDamien Diederen, Mar 27, 2008
  18. 3/7 cvsserver: Do not include status output for subdirectories if -l is passedDamien Diederen, Mar 27, 2008
  19. 4/7 cvsserver: Add a few tests for 'status' commandDamien Diederen, Mar 27, 2008
  20. 5/7 cvsserver: Implement update -p (print to stdout)Damien Diederen, Mar 27, 2008
  21. 6/7 cvsserver: Add test for update -pDamien Diederen, Mar 27, 2008
  22. 7/7 cvsserver: Use the user part of the email in log and annotate resultsDamien Diederen, Mar 27, 2008

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.