Read works

This commit is contained in:
Tobe O 2018-10-21 12:29:04 -04:00
parent e24c89f8d9
commit b5ad764072

View file

@ -20,6 +20,7 @@ main() async {
var output = await service.create(input);
expect(input, output);
});
test('create without id', () async {
var input = {'bar': 'baz'};
var output = await service.create(input);
@ -27,4 +28,10 @@ main() async {
expect(output.keys, contains('id'));
expect(output, containsPair('bar', 'baz'));
});
test('read', () async {
var id = 'poobah${new DateTime.now().millisecondsSinceEpoch}';
var input = await service.create({'id': id, 'bar': 'baz'});
expect(await service.read(id), input);
});
}