choo121600 commented on code in PR #63562:
URL: https://github.com/apache/airflow/pull/63562#discussion_r2938817427
##########
airflow-core/src/airflow/ui/tests/e2e/specs/plugins.spec.ts:
##########
@@ -37,36 +37,32 @@ test.describe("Plugins Page", () => {
await expect(pluginsPage.table).toBeVisible();
});
- test("verify plugins list displays with data", async () => {
- const count = await pluginsPage.getPluginCount();
-
- expect(count).toBeGreaterThan(0);
+ test("verify plugins list has at least one entry", async () => {
+ await expect(pluginsPage.rows).not.toHaveCount(0);
});
test("verify each plugin has a name", async () => {
- const pluginNames = await pluginsPage.getPluginNames();
-
- expect(pluginNames.length).toBeGreaterThan(0);
+ const count = await pluginsPage.rows.count();
- for (const name of pluginNames) {
- expect(name.trim().length).toBeGreaterThan(0);
+ expect(count).toBeGreaterThan(0);
Review Comment:
Could this be improved using a web-first assertion pattern like this?
```
await expect(pluginsPage.rows).not.toHaveCount(0);
const count = await pluginsPage.rows.count();
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]