Removed todos and added User endpoint combined with register. Id changed to guid

This commit is contained in:
Dominic Villemure
2024-04-03 23:57:01 -04:00
parent df8b42bdf1
commit 1f795c53bb
67 changed files with 1750 additions and 1895 deletions

View File

@@ -3,8 +3,6 @@ using System.Runtime.CompilerServices;
using AutoMapper;
using Hutopy.Application.Common.Interfaces;
using Hutopy.Application.Common.Models;
using Hutopy.Application.TodoItems.Queries.GetTodoItemsWithPagination;
using Hutopy.Application.TodoLists.Queries.GetTodos;
using Hutopy.Domain.Entities;
using NUnit.Framework;
@@ -17,7 +15,7 @@ public class MappingTests
public MappingTests()
{
_configuration = new MapperConfiguration(config =>
_configuration = new MapperConfiguration(config =>
config.AddMaps(Assembly.GetAssembly(typeof(IApplicationDbContext))));
_mapper = _configuration.CreateMapper();
@@ -29,19 +27,6 @@ public class MappingTests
_configuration.AssertConfigurationIsValid();
}
[Test]
[TestCase(typeof(TodoList), typeof(TodoListDto))]
[TestCase(typeof(TodoItem), typeof(TodoItemDto))]
[TestCase(typeof(TodoList), typeof(LookupDto))]
[TestCase(typeof(TodoItem), typeof(LookupDto))]
[TestCase(typeof(TodoItem), typeof(TodoItemBriefDto))]
public void ShouldSupportMappingFromSourceToDestination(Type source, Type destination)
{
var instance = GetInstanceOf(source);
_mapper.Map(instance, source, destination);
}
private object GetInstanceOf(Type type)
{
if (type.GetConstructor(Type.EmptyTypes) != null)