##// END OF EJS Templates
tests: unify test-username-newline
Adrian Buehlmann -
r12301:3a082866 default
parent child Browse files
Show More
@@ -1,22 +1,24 b''
1 #!/bin/sh
1 $ hg init
2 #
2 $ touch a
3
3
4 hg init foo
4 $ unset HGUSER
5 cd foo
5 $ echo "[ui]" >> .hg/hgrc
6 touch a
6 $ echo "username= foo" >> .hg/hgrc
7
7 $ echo " bar1" >> .hg/hgrc
8
8
9 unset HGUSER
9 $ hg ci -Am m
10 echo "[ui]" >> .hg/hgrc
10 adding a
11 echo "username= foo" >> .hg/hgrc
11 abort: username 'foo\nbar1' contains a newline
12 echo " bar1" >> .hg/hgrc
12
13
13 $ rm .hg/hgrc
14 hg ci -Am m
15
14
16 rm .hg/hgrc
15 $ HGUSER=`(echo foo; echo bar2)` hg ci -Am m
17
16 abort: username 'foo\nbar2' contains a newline
18 HGUSER=`(echo foo; echo bar2)` hg ci -Am m
17
18 $ hg ci -Am m -u "`(echo foo; echo bar3)`"
19 transaction abort!
20 rollback completed
21 abort: username 'foo\nbar3' contains a newline!
19
22
20 hg ci -Am m -u "`(echo foo; echo bar3)`"
23 $ true
21
24
22 true
1 NO CONTENT: file was removed
NO CONTENT: file was removed
General Comments 0
You need to be logged in to leave comments. Login now