MCPcopy Index your code
hub / github.com/ember-cli/ember-cli / watcherEventTest

Function watcherEventTest

tests/unit/tasks/server/livereload-server-test.js:245–252  ·  view source on GitHub ↗
(eventName, expectedCount)

Source from the content-addressed store, hash-verified

243
244 describe('watcher events', function () {
245 function watcherEventTest(eventName, expectedCount) {
246 subject.getDirectoryEntries = createStubbedGetDirectoryEntries(['test/fixtures/proxy/file-a.js']);
247 subject.project.liveReloadFilterPatterns = [];
248 watcher.emit(eventName, {
249 directory: '/home/user/projects/my-project/tmp/something.tmp',
250 });
251 return expect(changedCount).to.equal(expectedCount);
252 }
253
254 it('triggers a livereload change on a watcher change event', function () {
255 return watcherEventTest('change', 1);

Callers 1

Calls 2

emitMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…