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

Unified Diff: third_party/pkg/angular/test/playback/playback_http_spec.dart

Issue 1058283006: Update pubspecs and dependencies to get pkgbuild tests working. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 8 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/test/playback/playback_http_spec.dart
diff --git a/third_party/pkg/angular/test/playback/playback_http_spec.dart b/third_party/pkg/angular/test/playback/playback_http_spec.dart
deleted file mode 100644
index cc2a0230a6e8a152daf45df780316e21223f4a11..0000000000000000000000000000000000000000
--- a/third_party/pkg/angular/test/playback/playback_http_spec.dart
+++ /dev/null
@@ -1,75 +0,0 @@
-library playback_http_spec;
-
-import '../_specs.dart';
-import 'package:angular/playback/playback_http.dart';
-
-main() => describe('Playback HTTP', () {
- MockHttpBackend backend;
- beforeEach(module((Module m) {
- backend = new MockHttpBackend();
- var wrapper = new HttpBackendWrapper(backend);
- m
- ..value(HttpBackendWrapper, wrapper)
- ..type(PlaybackHttpBackendConfig);
- }));
-
- afterEach(() {
- backend.verifyNoOutstandingRequest();
- backend.verifyNoOutstandingExpectation();
- });
-
- describe('RecordingHttpBackend', () {
- beforeEach(module((Module m) {
- m.type(HttpBackend, implementedBy: RecordingHttpBackend);
- }));
-
-
- it('should record a request', async(inject((Http http) {
- backend.expectGET('request').respond(200, 'response');
-
- var responseData;
-
- http(method: 'GET', url: 'request').then((HttpResponse r) {
- responseData = r.data;
- });
-
- microLeap();
- backend.flush();
- backend
- .expectPOST('/record',
- r'{"key":"{\"url\":\"request\",\"method\":\"GET\",\"requestHeaders\":{\"Accept\":\"application/json, text/plain, */*\",\"X-XSRF-TOKEN\":\"secret\"},\"data\":null}",' +
- r'"data":"{\"status\":200,\"headers\":\"\",\"data\":\"response\"}"}')
- .respond(200);
-
- microLeap();
- backend.flush();
- microLeap();
-
- expect(responseData).toEqual('response');
- })));
- });
-
-
- describe('PlaybackHttpBackend', () {
- beforeEach(module((Module m) {
- m.type(HttpBackend, implementedBy: PlaybackHttpBackend);
- }));
-
- it('should replay a request', async(inject((Http http, HttpBackend hb) {
- (hb as PlaybackHttpBackend).data = {
- r'{"url":"request","method":"GET","requestHeaders":{"Accept":"application/json, text/plain, */*","X-XSRF-TOKEN":"secret"},"data":null}': {'status': 200, 'headers': '', 'data': 'playback data'}
- };
-
- var responseData;
-
- http(method: 'GET', url: 'request').then((HttpResponse r) {
- responseData = r.data;
- });
-
- microLeap();
-
- expect(responseData).toEqual('playback data');
- })));
-
- });
-});
« no previous file with comments | « third_party/pkg/angular/test/mock/zone_spec.dart ('k') | third_party/pkg/angular/test/routing/ng_bind_route_spec.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698