Bump to 2.0.0-alpha
This commit is contained in:
parent
239269acd3
commit
27f1d90c69
6 changed files with 27 additions and 22 deletions
1
.dart_tool/pub/bin/sdk-version
Normal file
1
.dart_tool/pub/bin/sdk-version
Normal file
|
@ -0,0 +1 @@
|
|||
2.0.0
|
BIN
.dart_tool/pub/bin/test/test.dart.snapshot.dart2
Normal file
BIN
.dart_tool/pub/bin/test/test.dart.snapshot.dart2
Normal file
Binary file not shown.
|
@ -1,3 +1,6 @@
|
|||
# 2.0.0-alpha
|
||||
* Depend on Dart 2 and Angel 2.
|
||||
|
||||
# 1.1.0+1
|
||||
* Dart 2/strong mode fixes.
|
||||
* Pass a `useZone` flag to `AngelHttp` through `TestServer`.
|
|
@ -11,30 +11,31 @@ main() {
|
|||
|
||||
setUp(() async {
|
||||
app = new Angel()
|
||||
..get('/hello', 'Hello')
|
||||
..get('/hello', (req, res) => 'Hello')
|
||||
..get(
|
||||
'/error',
|
||||
() => throw new AngelHttpException.forbidden(message: 'Test')
|
||||
(req, res) => throw new AngelHttpException.forbidden(message: 'Test')
|
||||
..errors.addAll(['foo', 'bar']))
|
||||
..get('/body', (ResponseContext res) {
|
||||
..get('/body', (req, res) {
|
||||
res
|
||||
..write('OK')
|
||||
..end();
|
||||
..close();
|
||||
})
|
||||
..get(
|
||||
'/valid',
|
||||
() => {
|
||||
(req, res) => {
|
||||
'michael': 'jackson',
|
||||
'billie': {'jean': 'hee-hee', 'is_my_lover': false}
|
||||
})
|
||||
..post('/hello', (req, res) async {
|
||||
return {'bar': req.body['foo']};
|
||||
var body = await req.parseBody();
|
||||
return {'bar': body['foo']};
|
||||
})
|
||||
..get('/gzip', (req, res) async {
|
||||
res
|
||||
..headers['content-encoding'] = 'gzip'
|
||||
..write(gzip.encode('Poop'.codeUnits))
|
||||
..end();
|
||||
..close();
|
||||
})
|
||||
..use(
|
||||
'/foo',
|
||||
|
|
15
pubspec.yaml
15
pubspec.yaml
|
@ -2,18 +2,17 @@ author: Tobe O <thosakwe@gmail.com>
|
|||
description: Testing utility library for the Angel framework.
|
||||
homepage: https://github.com/angel-dart/test.git
|
||||
name: angel_test
|
||||
version: 1.1.0+1
|
||||
version: 2.0.0-alpha
|
||||
dependencies:
|
||||
angel_client: ^1.1.0-alpha
|
||||
angel_framework: ^1.1.0-alpha
|
||||
angel_validate: ^1.0.0
|
||||
angel_websocket: ^1.1.0-alpha
|
||||
dart2_constant: ^1.0.0
|
||||
angel_client: ^2.0.0-alpha
|
||||
angel_framework: ^2.0.0-alpha
|
||||
angel_validate: ^2.0.0-alpha
|
||||
angel_websocket: ^2.0.0-alpha
|
||||
http: ^0.11.0
|
||||
matcher: ^0.12.0+2
|
||||
mock_request: ^1.0.0
|
||||
web_socket_channel: ^1.0.0
|
||||
dev_dependencies:
|
||||
test: ^0.12.17+2
|
||||
test: ^1.0.0
|
||||
environment:
|
||||
sdk: ">=1.8.9 <3.0.0"
|
||||
sdk: ">=2.0.0-dev <3.0.0"
|
||||
|
|
|
@ -12,30 +12,31 @@ main() {
|
|||
|
||||
setUp(() async {
|
||||
app = new Angel()
|
||||
..get('/hello', 'Hello')
|
||||
..get('/hello', (req, res) => 'Hello')
|
||||
..get(
|
||||
'/error',
|
||||
() => throw new AngelHttpException.forbidden(message: 'Test')
|
||||
(req, res) => throw new AngelHttpException.forbidden(message: 'Test')
|
||||
..errors.addAll(['foo', 'bar']))
|
||||
..get('/body', (ResponseContext res) {
|
||||
..get('/body', (req, res) {
|
||||
res
|
||||
..write('OK')
|
||||
..end();
|
||||
..close();
|
||||
})
|
||||
..get(
|
||||
'/valid',
|
||||
() => {
|
||||
(req, res) => {
|
||||
'michael': 'jackson',
|
||||
'billie': {'jean': 'hee-hee', 'is_my_lover': false}
|
||||
})
|
||||
..post('/hello', (req, res) async {
|
||||
return {'bar': req.body['foo']};
|
||||
var body = await req.parseBody();
|
||||
return {'bar': body['foo']};
|
||||
})
|
||||
..get('/gzip', (req, res) async {
|
||||
res
|
||||
..headers['content-encoding'] = 'gzip'
|
||||
..write(gzip.encode('Poop'.codeUnits))
|
||||
..end();
|
||||
..close();
|
||||
})
|
||||
..use(
|
||||
'/foo',
|
||||
|
|
Loading…
Reference in a new issue