From: Joel Teichroeb <joel@teichroeb.net>
To: git@vger.kernel.org
Cc: Joel Teichroeb <joel@teichroeb.net>
Subject: [PATCH 1/3] stash: add test for stash create with no files
Date: Sat, 19 Aug 2017 13:13:24 -0700 [thread overview]
Message-ID: <20170819201326.6872-1-joel@teichroeb.net> (raw)
Ensure the command suceeds and outputs nothing
Signed-off-by: Joel Teichroeb <joel@teichroeb.net>
---
t/t3903-stash.sh | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/t/t3903-stash.sh b/t/t3903-stash.sh
index 4046817d70..f0708ced27 100755
--- a/t/t3903-stash.sh
+++ b/t/t3903-stash.sh
@@ -444,6 +444,14 @@ test_expect_failure 'stash file to directory' '
test foo = "$(cat file/file)"
'
+test_expect_success 'stash create - no changes' '
+ git stash clear &&
+ test_when_finished "git reset --hard HEAD" &&
+ git reset --hard &&
+ git stash create >actual &&
+ test_must_be_empty actual
+'
+
test_expect_success 'stash branch - no stashes on stack, stash-like argument' '
git stash clear &&
test_when_finished "git reset --hard HEAD" &&
--
2.14.1
next reply other threads:[~2017-08-19 20:13 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-08-19 20:13 Joel Teichroeb [this message]
2017-08-19 20:13 ` [PATCH 2/3] stash: Add a test for when apply fails during stash branch Joel Teichroeb
2017-08-19 20:13 ` [PATCH 3/3] stash: add test for stashing in a detached state Joel Teichroeb
2017-08-19 20:55 ` [PATCH 1/3] stash: add test for stash create with no files Junio C Hamano
2017-08-19 21:00 ` Joel Teichroeb
2017-08-19 21:07 ` Junio C Hamano
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170819201326.6872-1-joel@teichroeb.net \
--to=joel@teichroeb.net \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).