public async Task AddToPolicyTests_PetNames(string name) { var pet = await _petProvider.Create( new Pet { Name = name, BreedName = "German Shepherd", PetOwnerId = 1, DateOfBirth = DateTime.UtcNow.AddYears(-1) }); pet.Name.Should().Be(name); pet.BreedName.Should().Be("German Shepherd"); pet.PetOwnerId.Should().Be(1); }
public async Task <IHttpActionResult> AddPetToPolicy(Pet pet) { var result = await _petProvider.Create(pet); return(Created(string.Empty, result)); }