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

Unified Diff: third_party/pkg/angular/lib/playback/playback_http.dart

Issue 176943008: Update the Angular/DI tests to latest from github. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 10 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
Index: third_party/pkg/angular/lib/playback/playback_http.dart
diff --git a/third_party/pkg/angular/lib/playback/playback_http.dart b/third_party/pkg/angular/lib/playback/playback_http.dart
index df57b95a2b8afed1511c6bb0a204abed4e09f4b4..f6253a3d9461e1808c373d88fac516d138cfb37f 100644
--- a/third_party/pkg/angular/lib/playback/playback_http.dart
+++ b/third_party/pkg/angular/lib/playback/playback_http.dart
@@ -13,9 +13,9 @@ import 'package:angular/playback/playback_data.dart' as playback_data;
@NgInjectableService()
class PlaybackHttpBackendConfig {
requestKey(String url,
- {String method, bool withCredentials, String responseType,
- String mimeType, Map<String, String> requestHeaders, sendData,
- void onProgress(ProgressEvent e)}) {
+ {String method, bool withCredentials, String responseType,
+ String mimeType, Map<String, String> requestHeaders, sendData,
+ void onProgress(ProgressEvent e)}) {
return JSON.encode({
"url": url,
"method": method,
@@ -29,7 +29,7 @@ class PlaybackHttpBackendConfig {
// the HttpBackend, but it will be implemented by ourselves.
class HttpBackendWrapper {
HttpBackend backend;
- HttpBackendWrapper(HttpBackend this.backend);
+ HttpBackendWrapper(this.backend);
}
class RecordingHttpBackend implements HttpBackend {
@@ -37,9 +37,8 @@ class RecordingHttpBackend implements HttpBackend {
HttpBackend _prodBackend;
PlaybackHttpBackendConfig _config;
- RecordingHttpBackend(HttpBackendWrapper wrapper, this._config) {
- this._prodBackend = wrapper.backend;
- }
+ RecordingHttpBackend(HttpBackendWrapper wrapper, this._config)
+ : _prodBackend = wrapper.backend;
Future request(String url,
{String method, bool withCredentials, String responseType,
@@ -97,9 +96,7 @@ class PlaybackHttpBackend implements HttpBackend {
sendData: sendData,
onProgress: onProgress);
- if (!data.containsKey(key)) {
- throw ["Request is not recorded $key"];
- }
+ if (!data.containsKey(key)) throw ["Request is not recorded $key"];
var playback = data[key];
return new Future.value(
new mock.MockHttpRequest(

Powered by Google App Engine
This is Rietveld 408576698