Esempio n. 1
0
        public async Task When_file_content_larger_than_buffer_size()
        {
            var          originalContent = string.Join("", Enumerable.Repeat("a#~×ψؾࢯ‽%1", 2000));
            const string filePath        = "test.txt";

            try
            {
                await AsyncFile.WriteText(filePath, originalContent, default);

                var content = await AsyncFile.ReadText(filePath, default);

                Assert.AreEqual(originalContent, content);
            }
            finally
            {
                File.Delete(filePath);
            }
        }