| OLD | NEW |
| (Empty) |
| 1 | |
| 2 library which.test.which; | |
| 3 | |
| 4 import 'package:path/path.dart'; | |
| 5 import 'package:unittest/unittest.dart'; | |
| 6 import 'package:which/which.dart'; | |
| 7 | |
| 8 main() { | |
| 9 group('which', () { | |
| 10 // Any dart:io supported platform (*nix, osx, windows) should have `find`. | |
| 11 test('should find `find`', () => which('find').then(_testResult)); | |
| 12 }); | |
| 13 | |
| 14 group('whichSync', () { | |
| 15 // Any dart:io supported platform (*nix, osx, windows) should have `find`. | |
| 16 test('should find `find`', () { | |
| 17 _testResult(whichSync('find')); | |
| 18 }); | |
| 19 }); | |
| 20 } | |
| 21 | |
| 22 _testResult(String path) { | |
| 23 expect(path, isNotNull); | |
| 24 var base = basenameWithoutExtension(path); | |
| 25 expect(base, 'find'); | |
| 26 } | |
| OLD | NEW |