Skip to content

Commit 4953da5

Browse files
committed
Officers now also return an empty object when the company doesn't exist instead of 404
1 parent 468cba7 commit 4953da5

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

tests/CompaniesHouse.IntegrationTests/Tests/OfficerTests/OfficersTestsInvalid.cs

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,13 @@ protected override async Task When()
1616
}
1717

1818
[Test]
19-
public void ThenTheDataItemsAreNull()
19+
public void ThenTheDataIsFullWithEmptyProperties()
2020
{
21-
Assert.That(Result.Data, Is.Null);
21+
Assert.That(Result.Data.Items, Is.Empty);
22+
Assert.That(Result.Data.ActiveCount, Is.EqualTo(0));
23+
Assert.That(Result.Data.ResignedCount,Is.EqualTo(0));
24+
Assert.That(Result.Data.StartIndex, Is.EqualTo(0));
25+
Assert.That(Result.Data.TotalResults, Is.EqualTo(0));;
2226
}
2327

2428
private async Task WhenRetrievingAnCompanyFilingHistoryForAnInvalidCompany()

0 commit comments

Comments
 (0)