Adding endpoint to create an inventory location

This commit is contained in:
hz
2025-08-21 00:37:20 -05:00
parent b7c221d765
commit 0ca7a31daa
2 changed files with 39 additions and 0 deletions
@@ -26,6 +26,19 @@ public class LocationControllerTests
mockLoc.Verify();
}
[Fact]
public async Task CreateInventory_ReturnsOk()
{
var mockLoc = new Mock<LocationService>(config);
mockLoc.Setup(l => l.CreateAsync(It.IsAny<Location>())).Returns(Task.CompletedTask).Verifiable();
var controller = new LocationController(mockLoc.Object, new Mock<PlayerService>(config).Object);
var result = await controller.CreateInventory();
Assert.IsType<OkObjectResult>(result);
mockLoc.Verify();
}
[Fact]
public async Task GetById_NotFound()
{