Failed to call method "create_test_run" in azure python api
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 25/100
Línea de trabajo
Compara las implementaciones de create_test_run mencionadas en azure/devops/v7_1/test_results/test_results_client.py y azure/devops/v7_1/test/test_client.py, centrándote en sus ID de ubicación y métodos del cliente. Reproduce la solicitud con los argumentos de RunCreateModel mostrados y determina por qué devuelve 404; se considera terminado cuando se identifica la operación correcta y se aclara el comportamiento o el uso del cliente.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Hi, i have a problem wih azure's python api. I self written function in python which calls official api from microscoft.
def create_test_run(self,
a_project_name: str = None,
a_comment: str = None,
a_test_run_name: str = None,
a_error_msg: str = None,
a_test_run_points=None,
a_test_plan=None
) -> TestRun:
"""create_test_run
:param str a_project_name: the name of the azure project where your test_plans are located
:param str a_comment: a comment that shall be added to the newly created test run
:param str a_test_run_name: the name of the test_run that shall be created
:param str a_error_msg: an error message for this test_run that can be displayed in azure
:param str a_test_run_points: a list of point_ids that reference azure TestPlan <-> TestSuite <-> TestCase relation
:param :class:`ShallowReference <azure.devops.v5_1.microsoft._team_foundation._test_management._web_api.models.ShallowReference>` a_test_plan: the test_plan for which this test_run shall be created
:rtype: :class:`<TestRun> <azure.devops.v5_1.test_results.models.TestRun>`
"""
if None in (a_project_name, a_test_run_name, a_test_run_points, a_test_plan):
raise InputError(
f"cannot create test_run in azure with a_project_name={a_project_name}, a_test_run_name={a_test_run_name}, a_test_run_points={a_test_run_points}, a_test_plan={a_test_plan}")
self. LOGGER.debug(
f"[create_test_run] creating create_test_run[{a_test_run_name}]")
test_run = RunCreateModel(automated=False,
comment=a_comment,
name=a_test_run_name,
error_message=a_error_msg,
plan=a_test_plan,
point_ids=a_test_run_points
# build=builds.value[0] #TODO: check if we can add a build :class:`ShallowReference <azure.devops.v5_1.microsoft._team_foundation._test_management._web_api.models.ShallowReference>`
)
return self.connection.clients_v5_1.get_test_results_client().create_test_run(test_run=test_run, project=a_project_name)
Every time we send this request, it gives a 404 error back, that the ressource does not exist. After looking carefully into the microscofts python api carefully i saw something. The function create_test_run in https://github.com/microsoft/azure-devops-python-api/blob/dev/azure-devops/azure/devops/v7_1/test_results/test_results_client.py only exists in the branches with a version number like dev5.1 and dev7.1. In the branch which is called dev, this function exists in another location which is https://github.com/microsoft/azure-devops-python-api/blob/dev/azure-devops/azure/devops/v7_1/test/test_client.py and the location ids are not identical. I would be very grateful if you can take a closer look to these source files.
Thank you and best regards,
Daniel
- Lenguaje dominante
- Python
- Estrellas
- 684
- Forks
- 218
- Merge medio
- 8 d 10 h
- PR fusionados (30 d)
- 1
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de microsoft/azure-devops-python-api
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 55/100
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
-
README sample code has a bug Abierto
Dificultad 1/5 Menos de una hora Aptitud para principiantes 55/100
-
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
-
Dificultad 3/5 1-2 días Aptitud para principiantes 45/100
Todos los issues de microsoft/azure-devops-python-api
Issues similares
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 90/100
learningequality/ricecooker#747 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
BSData/horus-heresy-3rd-edition#3171 ·
-
enhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
run-llama/llama_index#23199 ·
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
KhronosGroup/glTF-Blender-IO#2769 ·