pierrejeambrun commented on code in PR #58548:
URL: https://github.com/apache/airflow/pull/58548#discussion_r2569645618


##########
airflow-core/src/airflow/ui/tests/e2e/pages/LoginPage.ts:
##########
@@ -0,0 +1,93 @@
+/*!
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+import { expect } from "@playwright/test";
+import type { Locator, Page } from "@playwright/test";
+
+import { BasePage } from "./BasePage.ts";
+
+/**
+ * Login Page Object
+ */
+export class LoginPage extends BasePage {
+  // Page URLs
+  public static get loginUrl(): string {
+    return "/auth/login";
+  }
+
+  public readonly errorMessage: Locator;
+  public readonly loginButton: Locator;
+  public readonly passwordInput: Locator;
+  public readonly usernameInput: Locator;
+
+  public constructor(page: Page) {
+    super(page);
+
+    this.usernameInput = page.locator('input[name="username"]');
+    this.passwordInput = page.locator('input[name="password"]');
+    this.loginButton = page.locator('button[type="submit"]');

Review Comment:
   Could be great to handle both `SimpleAuthManager` and `FabAuthManager`. 
   
   The button is not found with `FabAuthManager` at the moment. I think it's a 
small adjustment to make to the selector. (if simplemanager button is not 
found, try the fabauthmanger selector)



-- 
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]

Reply via email to