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

[PATCH 1/5] git p4 test: move client_view() function to library

From
PWPete Wyckoff <pw@padd.com>
Date
Aug 11, 2012, 16:55 UTC
Message-ID
<1344704104-17727-1-git-send-email-pw@padd.com>
In-Reply-To
<20120811165143.GA2004@padd.com>
This code will be useful in --detect-branches --use-client-spec tests.
Signed-off-by: Pete Wyckoff <pw@padd.com>
---
 t/lib-git-p4.sh               | 18 ++++++++++++++++++
 t/t9809-git-p4-client-view.sh | 17 -----------------
 2 files changed, 18 insertions(+), 17 deletions(-)
diff --git a/t/lib-git-p4.sh b/t/lib-git-p4.sh
index 2d753ab..5c952d6 100644
--- a/t/lib-git-p4.sh
+++ b/t/lib-git-p4.sh
@@ -115,3 +115,21 @@ marshal_dump() {
 	EOF
 	"$PYTHON_PATH" "$TRASH_DIRECTORY/marshal-dump.py"
 }
+
+#
+# Construct a client with this list of View lines
+#
+client_view() {
+	(
+		cat <<-EOF &&
+		Client: client
+		Description: client
+		Root: $cli
+		View:
+		EOF
+		for arg ; do
+			printf "\t$arg\n"
+		done
+	) | p4 client -i
+}
+
diff --git a/t/t9809-git-p4-client-view.sh b/t/t9809-git-p4-client-view.sh
index 7d993ef..281be29 100755
--- a/t/t9809-git-p4-client-view.sh
+++ b/t/t9809-git-p4-client-view.sh
@@ -9,23 +9,6 @@ test_expect_success 'start p4d' '
 '
 
 #
-# Construct a client with this list of View lines
-#
-client_view() {
-	(
-		cat <<-EOF &&
-		Client: client
-		Description: client
-		Root: $cli
-		View:
-		EOF
-		for arg ; do
-			printf "\t$arg\n"
-		done
-	) | p4 client -i
-}
-
-#
 # Verify these files exist, exactly.  Caller creates
 # a list of files in file "files".
 #
-- 
1.7.12.rc2.24.gc304662
Previous: Pete WyckoffNext: Pete Wyckoff
Message 3 of 10 in “git-p4 migrates perforce “main” branch into git branches as subdirectories (doubled code in git branches)”
  1. Matthew KorichAug 10, 2012
  2. 0/5 git p4: fix branch detection with --use-client-specPete Wyckoff, Aug 11, 2012
  3. 1/5 git p4 test: move client_view() function to libraryPete Wyckoff, Aug 11, 2012
  4. 2/5 git p4 test: add broken --use-client-spec --detect-branches testsPete Wyckoff, Aug 11, 2012
  5. 3/5 git p4: set self.branchPrefixes in initializationPete Wyckoff, Aug 11, 2012
  6. 4/5 git p4: do wildcard decoding in stripRepoPathPete Wyckoff, Aug 11, 2012
  7. 5/5 git p4: make branch detection work with --use-client-specPete Wyckoff, Aug 11, 2012
  8. Junio C HamanoAug 12, 2012
  9. Pete WyckoffAug 12, 2012
  10. Junio C HamanoAug 12, 2012

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.