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

Unified Diff: utils/tests/pub/test_pub.dart

Issue 11276042: Explicitly configure git committer. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « utils/pub/io.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: utils/tests/pub/test_pub.dart
diff --git a/utils/tests/pub/test_pub.dart b/utils/tests/pub/test_pub.dart
index 87fe686af4dd4a150afa00c8f3309dbbb42ee93d..60eaa793ddc3ad9cdebf9baa4579a1d2a073226d 100644
--- a/utils/tests/pub/test_pub.dart
+++ b/utils/tests/pub/test_pub.dart
@@ -1050,16 +1050,19 @@ class GitRepoDescriptor extends DirectoryDescriptor {
return super.create(parentDir).chain((rootDir) {
workingDir = rootDir;
- return writeTextFile(join(parentDir, '.gitconfig'), '''
-[user]
- name = Test Pub
- email = pub@dartlang.org
-''');
- }).chain(runGitStep);
+ return runGitStep(null);
+ });
}
Future<String> _runGit(List<String> args, Directory workingDir) {
- return runGit(args, workingDir: workingDir.path).transform((result) {
+ // Explicitly specify the committer information. Git needs this to commit
+ // and we don't want to rely on the buildbots having this already set up.
+ var environment = new Map.from(Platform.environment);
nweiz 2012/10/26 18:34:06 Should the environment argument be automatically m
Bob Nystrom 2012/10/30 22:09:26 Done.
+ environment['GIT_COMMITTER_NAME'] = 'Pub Test';
+ environment['GIT_COMMITTER_EMAIL'] = 'pub@dartlang.org';
+
+ return runGit(args, workingDir: workingDir.path,
+ environment: environment).transform((result) {
if (!result.success) {
throw "Error running: git ${Strings.join(args, ' ')}\n"
"${Strings.join(result.stderr, '\n')}";
« no previous file with comments | « utils/pub/io.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698