// Create access token (not needed in this test, but prevents errors in daemon)
daemonConfig.setPortTO(TestDaemonUtil.createPortTO(port));
// Register to event bus
LocalEventBus localEventBus = LocalEventBus.getInstance();
localEventBus.register(this);
// Prepare CLI request
StatusFolderRequest cliStatusRequest = new StatusFolderRequest();
cliStatusRequest.setId(2586);
cliStatusRequest.setRoot(clientA.getConfig().getLocalDir().getAbsolutePath());
// Create watchServer
WatchServer watchServer = new WatchServer();
watchServer.start(daemonConfig);
Thread.sleep(1000); // Settlement for watch server
// Create large file, then wait 3sec for the settlement timer and
// send the CLI request at the same time
clientA.createNewFile("largefile", 10*1024*1024);
Thread.sleep(3000); // Settlement in Watcher!
localEventBus.post(cliStatusRequest);
// Then, let's hope the response is "no, no, no!"
Response response = waitForResponse(2586);
assertTrue(response instanceof StatusFolderResponse);