| OLD | NEW |
| 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 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 | 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.index.store.separate_file_mananer; | 5 library test.engine.src.index.store.separate_file_mananer; |
| 6 | 6 |
| 7 import 'dart:io'; | 7 import 'dart:io'; |
| 8 | 8 |
| 9 import 'package:analysis_server/src/index/store/separate_file_manager.dart'; | |
| 10 import 'package:path/path.dart'; | 9 import 'package:path/path.dart'; |
| 11 import 'package:unittest/unittest.dart'; | 10 import 'package:unittest/unittest.dart'; |
| 12 | 11 |
| 13 import '../../reflective_tests.dart'; | 12 import '../../reflective_tests.dart'; |
| 13 import 'package:analyzer/src/index/store/separate_file_manager.dart'; |
| 14 | 14 |
| 15 | 15 |
| 16 main() { | 16 main() { |
| 17 groupSep = ' | '; | 17 groupSep = ' | '; |
| 18 group('SeparateFileManager', () { | 18 group('SeparateFileManager', () { |
| 19 runReflectiveTests(_SeparateFileManagerTest); | 19 runReflectiveTests(_SeparateFileManagerTest); |
| 20 }); | 20 }); |
| 21 } | 21 } |
| 22 | 22 |
| 23 | 23 |
| 24 @ReflectiveTestCase() | 24 @ReflectiveTestCase() |
| 25 class _SeparateFileManagerTest { | 25 class _SeparateFileManagerTest { |
| 26 Directory tempDir; |
| 26 SeparateFileManager fileManager; | 27 SeparateFileManager fileManager; |
| 27 Directory tempDir; | |
| 28 | 28 |
| 29 void setUp() { | 29 void setUp() { |
| 30 tempDir = Directory.systemTemp.createTempSync('AnalysisServer_index'); | 30 tempDir = Directory.systemTemp.createTempSync('AnalysisServer_index'); |
| 31 fileManager = new SeparateFileManager(tempDir); | 31 fileManager = new SeparateFileManager(tempDir); |
| 32 } | 32 } |
| 33 | 33 |
| 34 void tearDown() { | 34 void tearDown() { |
| 35 tempDir.delete(recursive: true); | 35 tempDir.delete(recursive: true); |
| 36 } | 36 } |
| 37 | 37 |
| (...skipping 30 matching lines...) Expand all Loading... |
| 68 expect(bytes, isNull); | 68 expect(bytes, isNull); |
| 69 }); | 69 }); |
| 70 }); | 70 }); |
| 71 }); | 71 }); |
| 72 } | 72 } |
| 73 | 73 |
| 74 bool _existsSync(String name) { | 74 bool _existsSync(String name) { |
| 75 return new File(join(tempDir.path, name)).existsSync(); | 75 return new File(join(tempDir.path, name)).existsSync(); |
| 76 } | 76 } |
| 77 } | 77 } |
| OLD | NEW |