Skip to content

Commit

Permalink
refactor : show a test run link in end of log
Browse files Browse the repository at this point in the history
  • Loading branch information
gibiw committed Sep 27, 2024
1 parent b6ef5f2 commit 36e3468
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
6 changes: 6 additions & 0 deletions qase-python-commons/changelog.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
# [email protected]

## What's new

Show a test run link in end of log.

# [email protected]

## What's new
Expand Down
2 changes: 1 addition & 1 deletion qase-python-commons/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"

[project]
name = "qase-python-commons"
version = "3.1.6"
version = "3.1.7"
description = "A library for Qase TestOps and Qase Report"
readme = "README.md"
authors = [{name = "Qase Team", email = "[email protected]"}]
Expand Down
4 changes: 1 addition & 3 deletions qase-python-commons/src/qase/commons/client/api_v1_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ def complete_run(self, project_code: str, run_id: str) -> None:
return
try:
api_runs.complete_run(project_code, run_id)
self.logger.log(f"Run {run_id} was completed successfully", "info")
self.logger.log(f"Test run link: {self.web}/run/{project_code}/dashboard/{run_id}", "info")
except Exception as e:
self.logger.log(f"Error at completing run {run_id}: {e}", "error")
raise ReporterException(e)
Expand Down Expand Up @@ -107,8 +107,6 @@ def create_test_run(self, project_code: str, title: str, description: str, plan_
run_create=RunCreate(**{k: v for k, v in kwargs.items() if v is not None})
)

self.logger.log(f"Test run was created: {self.web}/run/{project_code}/dashboard/{result.result.id}", "info")

return result.result.id

except Exception as e:
Expand Down

0 comments on commit 36e3468

Please sign in to comment.