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

Side by Side Diff: pkg/gcloud/test/db/model_db_test.dart

Issue 804973002: Add appengine/gcloud/mustache dependencies. (Closed) Base URL: git@github.com:dart-lang/pub-dartlang-dart.git@master
Patch Set: Added AUTHORS/LICENSE/PATENTS files Created 6 years 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
OLDNEW
(Empty)
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
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.
4
5 library gcloud.db_impl_test;
6
7 import 'dart:async';
8
9 import 'package:gcloud/db.dart';
10 import 'package:unittest/unittest.dart';
11
12
13 // These unused imports make sure that [ModelDBImpl.fromLibrary()] will find
14 // all the Model/ModelDescription classes.
15 import 'model_dbs/duplicate_kind.dart' as test1;
16 import 'model_dbs/duplicate_property.dart' as test2;
17 import 'model_dbs/multiple_annotations.dart' as test3;
18 import 'model_dbs/duplicate_fieldname.dart' as test4;
19 import 'model_dbs/no_default_constructor.dart' as test5;
20
21 main() {
22 newModelDB(Symbol symbol)=> new ModelDBImpl.fromLibrary(symbol);
23
24 group('model_db', () {
25 group('from_library', () {
26 test('duplicate_kind', () {
27 expect(new Future.sync(() {
28 newModelDB(#gcloud.db.model_test.duplicate_kind);
29 }), throwsA(isStateError));
30 });
31 test('duplicate_property', () {
32 expect(new Future.sync(() {
33 newModelDB(#gcloud.db.model_test.duplicate_property);
34 }), throwsA(isStateError));
35 });
36 test('multiple_annotations', () {
37 expect(new Future.sync(() {
38 newModelDB(#gcloud.db.model_test.multiple_annotations);
39 }), throwsA(isStateError));
40 });
41 test('duplicate_fieldname', () {
42 expect(new Future.sync(() {
43 newModelDB(#gcloud.db.model_test.duplicate_fieldname);
44 }), throwsA(isStateError));
45 });
46 test('no_default_constructor', () {
47 expect(new Future.sync(() {
48 newModelDB(#gcloud.db.model_test.no_default_constructor);
49 }), throwsA(isStateError));
50 });
51 });
52 });
53 }
OLDNEW
« no previous file with comments | « pkg/gcloud/test/db/e2e/metamodel_test_impl.dart ('k') | pkg/gcloud/test/db/model_dbs/duplicate_fieldname.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698