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

Side by Side Diff: tests/lib/mirrors/static_test.dart

Issue 64793003: Update mirror tests for removed API. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: . Created 7 years, 1 month 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 | « tests/lib/mirrors/return_type_test.dart ('k') | tests/lib/mirrors/to_string_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
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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 // Test static members. 5 // Test static members.
6 6
7 import 'dart:mirrors'; 7 import 'dart:mirrors';
8 8
9 import 'stringify.dart'; 9 import 'stringify.dart';
10 10
11 class Foo { 11 class Foo {
12 static String bar = '...'; 12 static String bar = '...';
13 String aux = ''; 13 String aux = '';
14 static foo() {} 14 static foo() {}
15 baz() {} 15 baz() {}
16 } 16 }
17 17
18 void main() { 18 void main() {
19 expect('Variable(s(aux) in s(Foo))', 19 expect('Variable(s(aux) in s(Foo))',
20 reflectClass(Foo).members[new Symbol('aux')]); 20 reflectClass(Foo).declarations[new Symbol('aux')]);
21 expect('Method(s(baz) in s(Foo))', 21 expect('Method(s(baz) in s(Foo))',
22 reflectClass(Foo).members[new Symbol('baz')]); 22 reflectClass(Foo).declarations[new Symbol('baz')]);
23 expect('<null>', 23 expect('<null>',
24 reflectClass(Foo).setters[new Symbol('aux=')]); 24 reflectClass(Foo).declarations[new Symbol('aux=')]);
25 expect('Method(s(foo) in s(Foo), static)', 25 expect('Method(s(foo) in s(Foo), static)',
26 reflectClass(Foo).members[new Symbol('foo')]); 26 reflectClass(Foo).declarations[new Symbol('foo')]);
27 expect('Variable(s(bar) in s(Foo), static)', 27 expect('Variable(s(bar) in s(Foo), static)',
28 reflectClass(Foo).members[new Symbol('bar')]); 28 reflectClass(Foo).declarations[new Symbol('bar')]);
29 } 29 }
OLDNEW
« no previous file with comments | « tests/lib/mirrors/return_type_test.dart ('k') | tests/lib/mirrors/to_string_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698