public async Task ReturnHelloWorld() { // arrange var app = new WebApplication(); var client = app.CreateClient(); // act var response = await client.GetAsync("/"); // assert response.EnsureSuccessStatusCode(); string responseString = await response.Content.ReadAsStringAsync(); Assert.Equal("Hello World!", responseString); }