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

Side by Side Diff: test/emitter_test.dart

Issue 12225039: Support for observable models, fixes #259 (Closed) Base URL: https://github.com/dart-lang/web-ui.git@master
Patch Set: Created 7 years, 10 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
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 /** 5 /**
6 * These are not quite unit tests, since we build on top of the analyzer and the 6 * These are not quite unit tests, since we build on top of the analyzer and the
7 * html5parser to build the input for each test. 7 * html5parser to build the input for each test.
8 */ 8 */
9 library emitter_test; 9 library emitter_test;
10 10
11 import 'package:html5lib/dom.dart'; 11 import 'package:html5lib/dom.dart';
12 import 'package:unittest/compact_vm_config.dart'; 12 import 'package:unittest/compact_vm_config.dart';
13 import 'package:unittest/unittest.dart'; 13 import 'package:unittest/unittest.dart';
14 import 'package:web_ui/src/analyzer.dart'; 14 import 'package:web_ui/src/analyzer.dart';
15 import 'package:web_ui/src/code_printer.dart'; 15 import 'package:web_ui/src/code_printer.dart';
16 import 'package:web_ui/src/dart_parser.dart';
16 import 'package:web_ui/src/emitters.dart'; 17 import 'package:web_ui/src/emitters.dart';
17 import 'package:web_ui/src/file_system/path.dart' show Path; 18 import 'package:web_ui/src/file_system/path.dart' show Path;
18 import 'package:web_ui/src/html5_utils.dart'; 19 import 'package:web_ui/src/html5_utils.dart';
19 import 'package:web_ui/src/info.dart'; 20 import 'package:web_ui/src/info.dart';
20 import 'package:web_ui/src/messages.dart'; 21 import 'package:web_ui/src/messages.dart';
21 import 'testing.dart'; 22 import 'testing.dart';
22 23
23 main() { 24 main() {
24 useCompactVMConfiguration(); 25 useCompactVMConfiguration();
25 group('emit element field', () { 26 group('emit element field', () {
(...skipping 328 matching lines...) Expand 10 before | Expand all | Expand 10 after
354 355
355 Context _recurse(Element elem, bool isClass, int child) { 356 Context _recurse(Element elem, bool isClass, int child) {
356 var info = analyzeElement(elem, new Messages.silent()); 357 var info = analyzeElement(elem, new Messages.silent());
357 var context = new Context(isClass: isClass); 358 var context = new Context(isClass: isClass);
358 if (child != null) { 359 if (child != null) {
359 info = info.children[child]; 360 info = info.children[child];
360 } 361 }
361 new RecursiveEmitter(null, context).visit(info); 362 new RecursiveEmitter(null, context).visit(info);
362 return context; 363 return context;
363 } 364 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698