public void AppendAllText() { // Type var @this = new FileInfo(Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "Examples_System_IO_FileInfo_AppendAllText.txt")); // Intialization using (FileStream stream = @this.Create()) { } // Examples @this.AppendAllText("Fizz" + Environment.NewLine + "Buzz"); // Unit Test Assert.AreEqual("Fizz" + Environment.NewLine + "Buzz", @this.ReadToEnd()); }