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

Side by Side Diff: sdk/lib/_internal/pub/test/hosted/version_negotiation_test.dart

Issue 323073006: Cache version list results even when they fail. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Revise. Created 6 years, 6 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
« no previous file with comments | « sdk/lib/_internal/pub/pub.status ('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 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 pub_tests; 5 library pub_tests;
6 6
7 import 'package:scheduled_test/scheduled_server.dart'; 7 import 'package:scheduled_test/scheduled_server.dart';
8 import 'package:scheduled_test/scheduled_test.dart'; 8 import 'package:scheduled_test/scheduled_test.dart';
9 import 'package:shelf/shelf.dart' as shelf; 9 import 'package:shelf/shelf.dart' as shelf;
10 10
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 "url": server.url.then((url) => url.toString()) 48 "url": server.url.then((url) => url.toString())
49 } 49 }
50 } 50 }
51 }).create(); 51 }).create();
52 52
53 var pub = startPub(args: [command.name]); 53 var pub = startPub(args: [command.name]);
54 54
55 server.handle('GET', '/api/packages/foo', 55 server.handle('GET', '/api/packages/foo',
56 (request) => new shelf.Response(406)); 56 (request) => new shelf.Response(406));
57 57
58 // TODO(nweiz): this shouldn't request the versions twice (issue 11077).
59 server.handle('GET', '/api/packages/foo',
60 (request) => new shelf.Response(406));
61
62 pub.shouldExit(1); 58 pub.shouldExit(1);
63 59
64 pub.stderr.expect(emitsLines( 60 pub.stderr.expect(emitsLines(
65 "Pub 0.1.2+3 is incompatible with the current version of localhost.\n" 61 "Pub 0.1.2+3 is incompatible with the current version of localhost.\n"
66 "Upgrade pub to the latest version and try again.")); 62 "Upgrade pub to the latest version and try again."));
67 }); 63 });
68 }); 64 });
69 } 65 }
OLDNEW
« no previous file with comments | « sdk/lib/_internal/pub/pub.status ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698