Ejemplo n.º 1
0
        private void AssertAssetHasBeenUploaded(long version, Guid commitId)
        {
            var fileName = AssetStoreExtensions.GetFileName(assetId.ToString(), version);

            A.CallTo(() => assetStore.UploadAsync(commitId.ToString(), A <HasherStream> .Ignored, false, CancellationToken.None))
            .MustHaveHappened();
            A.CallTo(() => assetStore.CopyAsync(commitId.ToString(), fileName, CancellationToken.None))
            .MustHaveHappened();
            A.CallTo(() => assetStore.DeleteAsync(commitId.ToString()))
            .MustHaveHappened();
        }
        public AssetUserPictureStoreTests()
        {
            file = AssetStoreExtensions.GetFileName(userId, 0, "picture");

            sut = new AssetUserPictureStore(assetStore);
        }