OLD | NEW |
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, 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 library test.analyzer.src.util.absolute_path; | 5 library analyzer.test.src.util.absolute_path_test; |
6 | 6 |
7 import 'package:analyzer/src/util/absolute_path.dart'; | 7 import 'package:analyzer/src/util/absolute_path.dart'; |
8 import 'package:unittest/unittest.dart'; | 8 import 'package:unittest/unittest.dart'; |
9 | 9 |
10 import '../../reflective_tests.dart'; | 10 import '../../reflective_tests.dart'; |
11 import '../../utils.dart'; | 11 import '../../utils.dart'; |
12 | 12 |
13 main() { | 13 main() { |
14 initializeTestEnvironment(); | 14 initializeTestEnvironment(); |
15 runReflectiveTests(AbsolutePathContextPosixTest); | 15 runReflectiveTests(AbsolutePathContextPosixTest); |
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
131 expect(context.split(r'C:\path\to\foo'), [r'C:', r'path', r'to', r'foo']); | 131 expect(context.split(r'C:\path\to\foo'), [r'C:', r'path', r'to', r'foo']); |
132 expect(context.split(r'C:\path'), [r'C:', r'path']); | 132 expect(context.split(r'C:\path'), [r'C:', r'path']); |
133 } | 133 } |
134 | 134 |
135 void test_suffix() { | 135 void test_suffix() { |
136 expect( | 136 expect( |
137 context.suffix(r'C:\root\path', r'C:\root\path\a\b.dart'), r'a\b.dart'); | 137 context.suffix(r'C:\root\path', r'C:\root\path\a\b.dart'), r'a\b.dart'); |
138 expect(context.suffix(r'C:\root\path', r'C:\root\other.dart'), isNull); | 138 expect(context.suffix(r'C:\root\path', r'C:\root\other.dart'), isNull); |
139 } | 139 } |
140 } | 140 } |
OLD | NEW |