public override void Execute() { if (!File.Exists(this.Path)) { File.AppendAllText(this.Path, "Hello, world!", Encoding.UTF8); } }
public void ExamplesCreateFileJob() { CreateFileJob job = new CreateFileJob(); Assert.IsFalse(File.Exists(job.Path)); job.Execute(); Assert.IsTrue(File.Exists(job.Path)); }