More tests and WIP vibe work

This commit is contained in:
2026-07-18 15:07:21 -04:00
parent c8d10c19de
commit 6062d5b60c
25 changed files with 323 additions and 45 deletions
+23 -2
View File
@@ -9,15 +9,36 @@ public class AgentsPage : BasePage
}
public ILocator Grid => Page.Locator(".agents-grid");
public ILocator AgentCards => Page.Locator(".agent-card");
public ILocator SearchInput => Page.Locator(".search-input");
public async Task GotoAsync()
{
await NavigateToAsync("/agents");
}
public async Task WaitForGridAsync()
public async Task WaitForInteractiveAsync()
{
await Page.WaitForLoadStateAsync(LoadState.DOMContentLoaded);
try {
// Wait for the grid container with a much longer timeout for Telerik initialization
await Page.WaitForSelectorAsync(".agents-page", new PageWaitForSelectorOptions { Timeout = 30_000, State = WaitForSelectorState.Visible });
// Wait for the actual Telerik Grid to be rendered and populated
await Page.WaitForSelectorAsync(".k-grid", new PageWaitForSelectorOptions { Timeout = 30_000, State = WaitForSelectorState.Visible });
} catch (System.Exception ex) {
var content = await Page.ContentAsync();
var title = await Page.TitleAsync();
var url = Page.Url;
System.Console.WriteLine($"[DEBUG_LOG] FAILED to find Agents Grid. Error: {ex.Message}");
System.Console.WriteLine($"[DEBUG_LOG] URL: {url}, Title: {title}");
System.Console.WriteLine("[DEBUG_LOG] Page Content length: " + content.Length);
throw;
}
}
public async Task SearchAsync(string query)
{
await SearchInput.FillAsync(query);
await Page.WaitForLoadStateAsync(LoadState.NetworkIdle);
await Grid.WaitForAsync();
}
}