Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

Feature: PageFactory implementation for By/AppiumBy object types

Abierto
#1,940 2 comentarios 3 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 5 días

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
5/5
Tiempo estimado
Más de una semana
Aptitud para principiantes
20/100
Tipo de issue
Nueva funcionalidad
Claridad
Necesita aclaración
Estado de actividad
Estancado
Stack tecnológico
java
Área
mobile

Línea de trabajo

El issue describe una PageFactory personalizada propuesta para los tipos de objeto By y AppiumBy, pero no indica archivos, pruebas ni puntos de entrada. Confirma primero si la comunidad de Appium quiere esta funcionalidad e identifica el alcance esperado y los criterios de aceptación antes de la implementación.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

Description

TL;DR, I would like to know if there will be demand/usage for such an implementation. I have ready code if there is interest, the details are shared below.

Environment

  • Java client build version or git revision if you use some snapshot: 8.5.0
  • Appium server version or git revision if you use some snapshot: v2.0.0-beta.71

Details

I recently encountered the following struggle:

I was re-building a cross-platform testing solution and was about to implement changes with PageFactory, as it’s a very efficient way to build tests fast and with less code for 2 platforms at the same time. What happened is that one of the internal SDK’s, used by the project in question, got updated to Java 17 and created a compatibility issue with PageFactory (the problem is that PageFactory uses cglib, which is not maintained nor updated for Java17).

After some thinking I went ahead and implemented a custom and very simplified implementation of a custom PageFactory, which works with By, instead of WebElement. The reasons I did it like that are:

  • Simplicity - this way the code is quite simplified, without having to instantiate the actual WebElements right away and thus no need for complicated proxying of the objects.
  • Flexibility - WebElements are great but they are not as flexible as the By locators, and also can be acquired at will as long as you have the By for the given element, but not the other way around.

This ended up being quite effective and I was wondering if this is something that may be of interest/demand? I can contribute my code if moderators agree this could be useful for many many people, I just want to know if this is something that the Appium community may be interested in. It’s purpose will not only be a (more stable) alternative for PageFactory, but also maybe a successor for it, unless the Selenium community updates that part of Selenium to not depend on cglib.

Lenguaje dominante
Java
Estrellas
1.3k
Forks
755
Merge medio
5 d 14 h
PR fusionados (30 d)
8

Preparar el entorno

  • Sin Dockerfile ni archivo de Docker Compose
  • Tiene una plantilla de pull request
  • Sin guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de appium/java-client

Todos los issues de appium/java-client

Issues similares

Más issues de Java

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.