Example #1
0
        public async Task ListFileNames()
        {
            using (var b = new TestBucket())
            {
                var uploadTasksA = new[] { b.UploadFile("file2", "contentA2"), b.UploadFile("file1", "contentA1"), b.UploadFile("file0", "contentA0") };
                await Task.WhenAll(uploadTasksA);

                var uploadTasksB = new[] { b.UploadFile("file0", "contentB0"), b.UploadFile("file1", "contentB1"), b.UploadFile("file2", "contentB2") };
                await Task.WhenAll(uploadTasksA);

                var r = await b.ListFileNames();

                Assert.AreEqual(2, r.files.Count);
                r = await b.ListFileNames(r.nextFileName);

                Assert.AreEqual(1, r.files.Count);
            }
        }