OLD | NEW |
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 import 'package:scheduled_test/scheduled_test.dart'; | 5 import 'package:scheduled_test/scheduled_test.dart'; |
6 import 'package:watcher/src/directory_watcher/mac_os.dart'; | 6 import 'package:watcher/src/directory_watcher/mac_os.dart'; |
7 import 'package:watcher/watcher.dart'; | 7 import 'package:watcher/watcher.dart'; |
8 | 8 |
9 import 'shared.dart'; | 9 import 'shared.dart'; |
10 import '../utils.dart'; | 10 import '../utils.dart'; |
(...skipping 28 matching lines...) Expand all Loading... |
39 test('emits events for many nested files moved out then immediately back in', | 39 test('emits events for many nested files moved out then immediately back in', |
40 () { | 40 () { |
41 withPermutations((i, j, k) => | 41 withPermutations((i, j, k) => |
42 writeFile("dir/sub/sub-$i/sub-$j/file-$k.txt")); | 42 writeFile("dir/sub/sub-$i/sub-$j/file-$k.txt")); |
43 | 43 |
44 startWatcher(dir: "dir"); | 44 startWatcher(dir: "dir"); |
45 | 45 |
46 renameDir("dir/sub", "sub"); | 46 renameDir("dir/sub", "sub"); |
47 renameDir("sub", "dir/sub"); | 47 renameDir("sub", "dir/sub"); |
48 | 48 |
49 inAnyOrder(() { | 49 inAnyOrder(withPermutations((i, j, k) => |
50 withPermutations((i, j, k) => | 50 isRemoveEvent("dir/sub/sub-$i/sub-$j/file-$k.txt"))); |
51 expectRemoveEvent("dir/sub/sub-$i/sub-$j/file-$k.txt")); | |
52 }); | |
53 | 51 |
54 inAnyOrder(() { | 52 inAnyOrder(withPermutations((i, j, k) => |
55 withPermutations((i, j, k) => | 53 isAddEvent("dir/sub/sub-$i/sub-$j/file-$k.txt"))); |
56 expectAddEvent("dir/sub/sub-$i/sub-$j/file-$k.txt")); | |
57 }); | |
58 }); | 54 }); |
59 } | 55 } |
OLD | NEW |