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

Side by Side Diff: pkg/smoke/test/static_in_pieces_test.dart

Issue 802703004: remove smoke from the repo (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: 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 | Annotate | Revision Log
« no previous file with comments | « pkg/smoke/test/piece2.dart ('k') | pkg/smoke/test/static_test.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 /// Tests that a static configuration can be loaded in pieces, even with
6 /// deferred imports.
7 library smoke.test.static_in_pieces_test;
8
9 import 'package:unittest/unittest.dart';
10 import 'package:smoke/smoke.dart' show Declaration, PROPERTY, METHOD;
11 import 'package:smoke/static.dart' show useGeneratedCode, StaticConfiguration;
12 import 'piece1.dart' as p1;
13 import 'piece2.dart' deferred as p2;
14 import 'common.dart' as smoke_0;
15 import 'common.dart' as common show main;
16
17 abstract class _M0 {} // C & A
18
19 final configuration = new StaticConfiguration(
20 checkedMode: false,
21 getters: {
22 #i: (o) => o.i,
23 #inc0: (o) => o.inc0,
24 #inc1: (o) => o.inc1,
25 #inc2: (o) => o.inc2,
26 #toString: (o) => o.toString,
27 },
28 setters: {
29 #i: (o, v) { o.i = v; },
30 },
31 parents: {
32 smoke_0.AnnotB: smoke_0.Annot,
33 smoke_0.D: _M0,
34 smoke_0.E2: smoke_0.E,
35 smoke_0.F2: smoke_0.F,
36 _M0: smoke_0.C,
37 },
38 declarations: {
39 smoke_0.A: {
40 #i: const Declaration(#i, int),
41 #inc0: const Declaration(#inc0, Function, kind: METHOD),
42 #inc1: const Declaration(#inc1, Function, kind: METHOD),
43 #inc2: const Declaration(#inc2, Function, kind: METHOD),
44 #j: const Declaration(#j, int),
45 #j2: const Declaration(#j2, int, kind: PROPERTY),
46 },
47 smoke_0.B: {
48 #f: const Declaration(#f, int, isFinal: true),
49 #w: const Declaration(#w, int, kind: PROPERTY),
50 },
51 smoke_0.C: {
52 #b: const Declaration(#b, smoke_0.B),
53 #inc: const Declaration(#inc, Function, kind: METHOD),
54 #x: const Declaration(#x, int),
55 #y: const Declaration(#y, String),
56 },
57 smoke_0.D: {
58 #i2: const Declaration(#i2, int, kind: PROPERTY, isFinal: true),
59 #x2: const Declaration(#x2, int, kind: PROPERTY, isFinal: true),
60 },
61 smoke_0.E: {
62 #noSuchMethod: const Declaration(#noSuchMethod, Function, kind: METHOD),
63 #y: const Declaration(#y, int, kind: PROPERTY, isFinal: true),
64 },
65 smoke_0.E2: {},
66 smoke_0.F: {
67 #staticMethod: const Declaration(#staticMethod, Function, kind: METHOD, isStatic: true),
68 },
69 smoke_0.F2: {},
70 smoke_0.G: {
71 #b: const Declaration(#b, int, annotations: const [smoke_0.a1]),
72 #d: const Declaration(#d, int, annotations: const [smoke_0.a2]),
73 },
74 _M0: {
75 #i: const Declaration(#i, int),
76 #inc: const Declaration(#inc, Function, kind: METHOD),
77 #inc0: const Declaration(#inc0, Function, kind: METHOD),
78 #j: const Declaration(#j, int),
79 #j2: const Declaration(#j2, int, kind: PROPERTY),
80 },
81 },
82 staticMethods: {},
83 names: {});
84
85 main() {
86 useGeneratedCode(configuration);
87
88 expect(configuration.getters[#j], isNull);
89
90 configuration.addAll(p1.configuration);
91 expect(configuration.getters[#j], isNotNull);
92
93 p2.loadLibrary().then((_) {
94 expect(configuration.names[#i], isNull);
95 configuration.addAll(p2.configuration);
96 expect(configuration.names[#i], 'i');
97 common.main();
98 });
99 }
OLDNEW
« no previous file with comments | « pkg/smoke/test/piece2.dart ('k') | pkg/smoke/test/static_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698