frasermclean / adoptrix

Pet adoption centre platform
https://demo.adoptrix.com
MIT License
1 stars 0 forks source link

Add Gridify library and refactor services #102

Closed frasermclean closed 3 weeks ago

github-actions[bot] commented 3 weeks ago

Solution test results

93 tests   - 5   93 :white_check_mark:  - 5   15s :stopwatch: +3s  5 suites  - 1    0 :zzz: ±0   5 files    - 1    0 :x: ±0 

Results for commit f477229f. ± Comparison against base commit 2c4da41b.

This pull request removes 22 and adds 17 tests. Note that renamed tests count towards both. ``` Adoptrix.Core.Tests.AnimalTests ‑ Delete_WithValidUserId_ShouldMarkAnimalAsDeleted Adoptrix.Core.Tests.AnimalTests ‑ Update_WithValidRequest_ShouldUpdateAnimal Adoptrix.Core.Tests.BreedTests ‑ Update_WithValidParameters_ShouldUpdateProperties Adoptrix.Core.Tests.Extensions.AddAnimalRequestExtensionsTests ‑ ToAnimal_WithValidRequest_ShouldReturnExpectedAnimal Adoptrix.Core.Tests.Extensions.AddBreedRequestExtensionsTests ‑ ToBreed_WithValidRequest_ReturnsBreed Adoptrix.Jobs.Tests.Functions.CleanupDeletedAnimalTests ‑ ExecuteAsync_WithValidEventData_ShouldPass(eventData: AnimalDeletedEvent { AnimalSlug = AnimalSluge3842424-680b-4bf9-b4fd-3f4f8502d71d }, animalImagesManagerMock: Mock, function: CleanupDeletedAnimal { }) Adoptrix.Jobs.Tests.Functions.ProcessAnimalImageTests ‑ ExecuteAsync_WithInvalidAnimalSlug_ShouldThrowException(data: AnimalImageAddedEvent { AnimalSlug = AnimalSlugcabf9956-dedf-4861-a508-df2c0ce1b5a8, ImageId = 158cbd9c-190d-4ac8-88cd-9ae774037a64, BlobName = BlobNamebf08fa11-86ed-460b-968b-d5703de150d9 }, animalImagesManagerMock: Mock, function: ProcessAnimalImage { }) Adoptrix.Jobs.Tests.Functions.ProcessAnimalImageTests ‑ ExecuteAsync_WithValidEventData_ShouldPass(data: AnimalImageAddedEvent { AnimalSlug = AnimalSlugd68df899-a306-4fab-98d6-838f0448829b, ImageId = db5dd845-ee56-4994-9540-5735c95db799, BlobName = BlobName0f3f6fe4-3af2-4bb9-a9ec-546b36f7949b }, animalImagesManagerMock: Mock, function: ProcessAnimalImage { }) Adoptrix.Logic.Tests.AppRoleIdMappingTests ‑ GetAppRoleId_WithAdministratorUserRole_ShouldReturnAdministratorRoleId Adoptrix.Logic.Tests.Services.ImageProcessorTests ‑ ProcessImageAsync_WhenCalledWithValidStream_ThenCreatesThumbnail(filePath: "Data/lab_puppy_1.jpeg") … ``` ``` Adoptrix.Api.Tests.Security.AppRoleIdMappingTests ‑ GetAppRoleId_WithAdministratorUserRole_ShouldReturnAdministratorRoleId Adoptrix.Api.Tests.Services.UserManagerTests ‑ AddUserRoleAssignmentAsync_WhenRoleIsAlreadyAssigned_ShouldReturnError Adoptrix.Api.Tests.Services.UserManagerTests ‑ AddUserRoleAssignmentAsync_WhenUserDoesNotExist_ShouldReturnError Adoptrix.Api.Tests.Services.UserManagerTests ‑ AddUserRoleAssignmentAsync_WithValidRole_ShouldReturnSuccess Adoptrix.Api.Tests.Services.UserManagerTests ‑ GetAllUsersAsync_WithValidResponse_ShouldReturnUsers Adoptrix.Api.Tests.Services.UserManagerTests ‑ GetUserAsync_WithInvalidUserId_ShouldReturnError Adoptrix.Api.Tests.Services.UserManagerTests ‑ GetUserAsync_WithValidUserId_ShouldReturnUser Adoptrix.Api.Tests.Services.UserManagerTests ‑ RemoveUserRoleAssignmentAsync_WithNoExistentRole_ShouldReturnError Adoptrix.Api.Tests.Services.UserManagerTests ‑ RemoveUserRoleAssignmentAsync_WithValidRole_ShouldReturnSuccess Adoptrix.Core.Tests.AnimalImageTests ‑ NewAnimalImage_ShouldHaveExpectedProperties … ```

:recycle: This comment has been updated with latest results.

codecov[bot] commented 3 weeks ago

Codecov Report

Attention: Patch coverage is 95.48193% with 15 lines in your changes missing coverage. Please review.

Project coverage is 76.77%. Comparing base (2c4da41) to head (f477229).

Files with missing lines Patch % Lines
src/Adoptrix.Api/Startup/ServiceRegistration.cs 45.83% 13 Missing :warning:
...ndpoints/Animals/Images/AddAnimalImagesEndpoint.cs 97.43% 0 Missing and 1 partial :warning:
...optrix.Persistence/Services/ServiceRegistration.cs 66.66% 1 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #102 +/- ## ========================================== + Coverage 74.98% 76.77% +1.78% ========================================== Files 139 122 -17 Lines 1775 1550 -225 Branches 120 94 -26 ========================================== - Hits 1331 1190 -141 + Misses 419 338 -81 + Partials 25 22 -3 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.