public void TestInvalidFile() { service.Start(); string outPath = Path.Combine(tmpDir, "test" + Constants.CAT_TEMPLATE_EXT); FileStream file = File.OpenWrite(outPath); file.Write(new byte [] { 1, 2, 3, 4 }, 0, 4); file.Flush(); file.Close(); monitor.AddFile(outPath); Assert.IsTrue(File.Exists(outPath)); service.Stop(); }
public void TestInvalidDirectory() { service = new ImportMonitorServices("/" + Path.GetRandomFileName(), new DummyMonitor()); Assert.IsFalse(service.Start()); }