Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(356)

Side by Side Diff: tests/test-lib.sh

Issue 203383005: in progress (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/depot_tools
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« tests/push-basic.sh ('K') | « tests/push-basic.sh ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/bin/bash 1 #!/bin/bash
2 2
3 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 3 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be 4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 6
7 # Abort on error. 7 # Abort on error.
8 set -e 8 set -e
9 9
10 export DEPOT_TOOLS_UPDATE=0 10 export DEPOT_TOOLS_UPDATE=0
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
93 git init -q 93 git init -q
94 git config user.name 'TestDood' 94 git config user.name 'TestDood'
95 git config user.email 'TestDood@example.com' 95 git config user.email 'TestDood@example.com'
96 echo "test" > test 96 echo "test" > test
97 git add test 97 git add test
98 git commit -qam "initial commit" 98 git commit -qam "initial commit"
99 echo "test2" >> test 99 echo "test2" >> test
100 git commit -qam "second commit" 100 git commit -qam "second commit"
101 # Hack: make sure master is not the current branch 101 # Hack: make sure master is not the current branch
102 # otherwise push will give a warning 102 # otherwise push will give a warning
103 git checkout -q -b foo 103 git checkout -q --detach master
104 ) 104 )
105 } 105 }
106 106
107 # Set up a git checkout of the repo. 107 # Set up a git checkout of the repo.
108 setup_gitgit() { 108 setup_gitgit() {
109 echo "Setting up test git repo..." 109 echo "Setting up test git repo..."
110 rm -rf git-git 110 rm -rf git-git
111 git clone -q $GITREPO_URL git-git 111 git clone -q $GITREPO_URL git-git
112 ( 112 (
113 cd git-git 113 cd git-git
(...skipping 27 matching lines...) Expand all
141 return $exit_code 141 return $exit_code
142 fi 142 fi
143 } 143 }
144 144
145 # Grab the XSRF token from the review server and print it to stdout. 145 # Grab the XSRF token from the review server and print it to stdout.
146 print_xsrf_token() { 146 print_xsrf_token() {
147 curl --cookie dev_appserver_login="test@example.com:False" \ 147 curl --cookie dev_appserver_login="test@example.com:False" \
148 --header 'X-Requesting-XSRF-Token: 1' \ 148 --header 'X-Requesting-XSRF-Token: 1' \
149 http://localhost:10000/xsrf_token 2>/dev/null 149 http://localhost:10000/xsrf_token 2>/dev/null
150 } 150 }
OLDNEW
« tests/push-basic.sh ('K') | « tests/push-basic.sh ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698