public void CopyFile() { CopyFileSample copyFileSample = new CopyFileSample(); ListFilesSample listFilesSample = new ListFilesSample(); copyFileSample.CopyFile(_fixture.BucketNameGeneric, _fixture.FileName, _fixture.BucketNameRegional, _fixture.CollectRegionalObject("CopyFile.txt")); var files = listFilesSample.ListFiles(_fixture.BucketNameRegional); Assert.Contains(files, c => c.Name == "CopyFile.txt"); }
public void ListFiles() { ListFilesSample listFilesSample = new ListFilesSample(); UploadFileSample uploadFileSample = new UploadFileSample(); uploadFileSample.UploadFile(_bucketFixture.BucketNameGeneric, _bucketFixture.FilePath, _bucketFixture.Collect("HelloListObjectsTest.txt")); var files = listFilesSample.ListFiles(_bucketFixture.BucketNameGeneric); Assert.Contains(files, c => c.Name == "HelloListObjectsTest.txt"); }
public void DeleteFile() { UploadFileSample uploadFileSample = new UploadFileSample(); DeleteFileSample deleteFileSample = new DeleteFileSample(); ListFilesSample listFilesSample = new ListFilesSample(); uploadFileSample.UploadFile(_bucketFixture.BucketNameGeneric, _bucketFixture.FilePath, "DeleteTest.txt"); deleteFileSample.DeleteFile(_bucketFixture.BucketNameGeneric, "DeleteTest.txt"); var files = listFilesSample.ListFiles(_bucketFixture.BucketNameGeneric).ToList(); Assert.DoesNotContain(files, c => c.Name == "DeleteTest.txt"); }
public void UploadFile() { UploadFileSample uploadFileSample = new UploadFileSample(); ListFilesSample listFilesSample = new ListFilesSample(); // upload file uploadFileSample.UploadFile(_bucketFixture.BucketNameGeneric, _bucketFixture.FilePath, _bucketFixture.Collect("UploadTest.txt")); var files = listFilesSample.ListFiles(_bucketFixture.BucketNameGeneric); Assert.Contains(files, c => c.Name == "UploadTest.txt"); }