Esempio n. 1
0
        public async Task GetLinkedRecordsInfo_ShouldReturnEmptyDictionary()
        {
            var(_, _, recImgSvc, _, context) = await CreateRecordWithLinkedImage();  // not empty db

            var imageId = Create_Image(context);

            var recordsDict = await recImgSvc.GetLinkedRecordsInfo(imageId);

            recordsDict.Should().NotBeNull();
            recordsDict.Should().BeEmpty();
        }
Esempio n. 2
0
        private async Task UpdateModel(Guid imageId)
        {
            string url = Request.GetAppBaseUrl();

            Image = await _imagesService.FetchImageById(imageId);

            ImageUrl   = new Uri($@"{url}/api/v1.0/image-file/{Image.Id}");
            ImageLinks = await _recordImagesService.GetLinkedRecordsInfo(imageId);
        }