tests: setup initial infra for end to end tests

This commit is contained in:
Stevan Freeborn
2024-04-03 16:21:38 -05:00
parent c7c24965b3
commit 1f5d45f003
10 changed files with 98 additions and 3 deletions
+19
View File
@@ -0,0 +1,19 @@
namespace Blog.Tests.EndToEnd;
public class BlogPageTest : PageTest
{
private readonly BlogHostFactory<Program> _factory = new();
public override BrowserNewContextOptions ContextOptions()
{
var baseUrl = "http://localhost:5000";
_factory
.WithWebHostBuilder(builder => builder.UseUrls(baseUrl))
.CreateDefaultClient();
var options = base.ContextOptions();
options.BaseURL = baseUrl;
return options;
}
}