File tree Expand file tree Collapse file tree 4 files changed +35
-2
lines changed
Expand file tree Collapse file tree 4 files changed +35
-2
lines changed Original file line number Diff line number Diff line change 1+ ## 1.26.3
2+
3+ * Fix a bug where ` --watch ` mode could go into an infinite loop compiling CSS
4+ files to themselves.
5+
16## 1.26.2
27
38* More aggressively eliminate redundant selectors in the ` selector.extend() ` and
Original file line number Diff line number Diff line change @@ -267,7 +267,7 @@ class _Watcher {
267267 p.setExtension (p.relative (source, from: sourceDir), '.css' ));
268268
269269 // Don't compile ".css" files to their own locations.
270- if (destination != source) return destination;
270+ if (! p. equals ( destination, source) ) return destination;
271271 }
272272
273273 return null ;
Original file line number Diff line number Diff line change 11name : sass
2- version : 1.26.2
2+ version : 1.26.3
33description : A Sass implementation in Dart.
44author : Sass Team
55homepage : https://github.com/sass/dart-sass
Original file line number Diff line number Diff line change @@ -173,6 +173,34 @@ void sharedTests(Future<TestProcess> runSass(Iterable<String> arguments)) {
173173 ]).validate ();
174174 });
175175
176+ test (
177+ "when it's modified twice when watched from a directory that is "
178+ "also a destination" , () async {
179+ await d.file ("test.scss" , "a {b: c}" ).create ();
180+
181+ var sass = await watch (["." ]);
182+ await expectLater (
183+ sass.stdout, emits ('Compiled test.scss to test.css.' ));
184+ await expectLater (sass.stdout, _watchingForChanges);
185+ await tickIfPoll ();
186+
187+ await d.file ("test.scss" , "r {o: g}" ).create ();
188+ await expectLater (
189+ sass.stdout, emits ('Compiled test.scss to test.css.' ));
190+
191+ await tickIfPoll ();
192+
193+ await d.file ("test.scss" , "x {y: z}" ).create ();
194+ await expectLater (
195+ sass.stdout, emits ('Compiled test.scss to test.css.' ));
196+
197+ await sass.kill ();
198+
199+ await d
200+ .file ("test.css" , equalsIgnoringWhitespace ("x { y: z; }" ))
201+ .validate ();
202+ });
203+
176204 group ("when its dependency is modified" , () {
177205 test ("through @import" , () async {
178206 await d.file ("_other.scss" , "a {b: c}" ).create ();
You can’t perform that action at this time.
0 commit comments