OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2013, the Dart project authors. | 2 * Copyright (c) 2013, the Dart project authors. |
3 * | 3 * |
4 * Licensed under the Eclipse Public License v1.0 (the "License"); you may not u
se this file except | 4 * Licensed under the Eclipse Public License v1.0 (the "License"); you may not u
se this file except |
5 * in compliance with the License. You may obtain a copy of the License at | 5 * in compliance with the License. You may obtain a copy of the License at |
6 * | 6 * |
7 * http://www.eclipse.org/legal/epl-v10.html | 7 * http://www.eclipse.org/legal/epl-v10.html |
8 * | 8 * |
9 * Unless required by applicable law or agreed to in writing, software distribut
ed under the License | 9 * Unless required by applicable law or agreed to in writing, software distribut
ed under the License |
10 * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY K
IND, either express | 10 * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY K
IND, either express |
(...skipping 28 matching lines...) Expand all Loading... |
39 public void test_argumentDefinitionTestNonParameter_optionalParameter() throws
Exception { | 39 public void test_argumentDefinitionTestNonParameter_optionalParameter() throws
Exception { |
40 Source source = addSource(createSource(// | 40 Source source = addSource(createSource(// |
41 "f([var v]) {", | 41 "f([var v]) {", |
42 " return ?v;", | 42 " return ?v;", |
43 "}")); | 43 "}")); |
44 resolve(source); | 44 resolve(source); |
45 assertNoErrors(); | 45 assertNoErrors(); |
46 verify(source); | 46 verify(source); |
47 } | 47 } |
48 | 48 |
| 49 public void test_assignmentToFinals_importWithPrefix() throws Exception { |
| 50 Source source = addSource(createSource(// |
| 51 "library lib;", |
| 52 "import 'lib1.dart' as foo;", |
| 53 "main() {", |
| 54 " foo.x = true;", |
| 55 "}")); |
| 56 addSource("/lib1.dart", createSource(// |
| 57 "library lib1;", |
| 58 "bool x = false;")); |
| 59 resolve(source); |
| 60 assertNoErrors(); |
| 61 verify(source); |
| 62 } |
| 63 |
49 public void test_breakWithoutLabelInSwitch() throws Exception { | 64 public void test_breakWithoutLabelInSwitch() throws Exception { |
50 Source source = addSource(createSource(// | 65 Source source = addSource(createSource(// |
51 "class A {", | 66 "class A {", |
52 " void m(int i) {", | 67 " void m(int i) {", |
53 " switch (i) {", | 68 " switch (i) {", |
54 " case 0:", | 69 " case 0:", |
55 " break;", | 70 " break;", |
56 " }", | 71 " }", |
57 " }", | 72 " }", |
58 "}")); | 73 "}")); |
(...skipping 874 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
933 public void test_wrongNumberOfParametersForSetter() throws Exception { | 948 public void test_wrongNumberOfParametersForSetter() throws Exception { |
934 Source source = addSource(createSource(// | 949 Source source = addSource(createSource(// |
935 "class A {", | 950 "class A {", |
936 " set x(a) {}", | 951 " set x(a) {}", |
937 "}")); | 952 "}")); |
938 resolve(source); | 953 resolve(source); |
939 assertNoErrors(); | 954 assertNoErrors(); |
940 verify(source); | 955 verify(source); |
941 } | 956 } |
942 } | 957 } |
OLD | NEW |