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

[StGit PATCH 1/2] Try "stg sink" without applied patches

From
Karl Hasselström <kha@treskal.com>
Date
Jun 29, 2008, 22:45 UTC
Message-ID
<20080629224541.9267.19258.stgit@yoghurt>
In-Reply-To
<20080629224440.9267.3591.stgit@yoghurt>

It doesn't work, neither with an implicit nor an explicit patch to sink. This is bug 11887 in the bug tracker.

(The implicit sink testcase actually passes, but that's just because the test suite can't distinguish between a program bug and an orderly abort.)

The test was adapted from the script attached to the bug report, written by Erik Sandberg.

Signed-off-by: Karl Hasselström <kha@treskal.com>
---
 t/t1501-sink.sh |   28 ++++++++++++++++++++++++++++
 1 files changed, 28 insertions(+), 0 deletions(-)
 create mode 100755 t/t1501-sink.sh
diff --git a/t/t1501-sink.sh b/t/t1501-sink.sh
new file mode 100755
index 0000000..3872c4b
--- /dev/null
+++ b/t/t1501-sink.sh
@@ -0,0 +1,28 @@
+#!/bin/sh
+
+test_description='Test "stg sink"'
+
+. ./test-lib.sh
+
+test_expect_success 'Initialize StGit stack' '
+    echo 000 >> x &&
+    git add x &&
+    git commit -m initial &&
+    echo 000 >> y &&
+    git add y &&
+    git commit -m y &&
+    stg init &&
+    stg uncommit &&
+    stg pop
+'
+
+test_expect_success 'sink without applied patches' '
+    ! stg sink
+'
+
+test_expect_failure 'sink a specific patch without applied patches' '
+    stg sink y &&
+    test $(echo $(stg applied)) = "y"
+'
+
+test_done
Previous: Karl HasselströmNext: Sverre Rabbelier
Message 2 of 5 in “Test+fix for bug 11887 (stg sink)”
  1. 0/2 Test+fix for bug 11887 (stg sink)Karl Hasselström, Jun 29, 2008
  2. 1/2 Try "stg sink" without applied patchesKarl Hasselström, Jun 29, 2008
  3. Sverre RabbelierJun 30, 2008
  4. Karl HasselströmJun 30, 2008
  5. 2/2 Fix "stg sink" with no applied patches (bug 11887)Karl Hasselström, Jun 29, 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.