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

Side by Side Diff: test/common_e2e.dart

Issue 2731933004: Remove FilterRelation.In / "property IN" queries, upgrade googleapis{,_beta} dependencies (Closed)
Patch Set: add pubspec.yaml update Created 3 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
« no previous file with comments | « pubspec.yaml ('k') | test/datastore/e2e/datastore_test_impl.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library gcloud.test.common_e2e; 5 library gcloud.test.common_e2e;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 import 'dart:io'; 8 import 'dart:io';
9 9
10 import 'package:unittest/unittest.dart'; 10 import 'package:unittest/unittest.dart';
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 envName = 'USERNAME'; 44 envName = 'USERNAME';
45 } else { 45 } else {
46 envName = 'USER'; 46 envName = 'USER';
47 } 47 }
48 return Platform.environment[envName] == 'chrome-bot'; 48 return Platform.environment[envName] == 'chrome-bot';
49 } 49 }
50 50
51 // Get the service key from the specified location. 51 // Get the service key from the specified location.
52 Future<String> serviceKeyJson(String serviceKeyLocation) { 52 Future<String> serviceKeyJson(String serviceKeyLocation) {
53 if (!serviceKeyLocation.startsWith('gs://')) { 53 if (!serviceKeyLocation.startsWith('gs://')) {
54 throw new Exception('Service key location must start with gs://'); 54 return new File(serviceKeyLocation).readAsString();
55 } 55 }
56 var future; 56 var future;
57 if (onBot()) { 57 if (onBot()) {
58 future = Process.run( 58 future = Process.run(
59 'python', ['third_party/gsutil/gsutil', 'cat', serviceKeyLocation], 59 'python', ['third_party/gsutil/gsutil', 'cat', serviceKeyLocation],
60 runInShell: true); 60 runInShell: true);
61 } else { 61 } else {
62 var gsutil = Platform.isWindows ? 'gsutil.cmd' : 'gsutil'; 62 var gsutil = Platform.isWindows ? 'gsutil.cmd' : 'gsutil';
63 future = Process.run(gsutil, ['cat', serviceKeyLocation]); 63 future = Process.run(gsutil, ['cat', serviceKeyLocation]);
64 } 64 }
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 111
112 Future get done => _completer.future; 112 Future get done => _completer.future;
113 113
114 onDone(success) { 114 onDone(success) {
115 new Future.sync(() { 115 new Future.sync(() {
116 super.onDone(success); 116 super.onDone(success);
117 }).then((_) => _completer.complete(_)) 117 }).then((_) => _completer.complete(_))
118 .catchError((error, stack) => _completer.completeError(error, stack)); 118 .catchError((error, stack) => _completer.completeError(error, stack));
119 } 119 }
120 } 120 }
OLDNEW
« no previous file with comments | « pubspec.yaml ('k') | test/datastore/e2e/datastore_test_impl.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698