Untitled
unknown
plain_text
a year ago
882 B
9
Indexable
def get_status_statistics(self, test_id: str): url = 'http://tinyurl.com/api-create.php?url=' static_url = "https://g-e479d6ef8a.grafana-workspace.us-west-2.amazonaws.com/d/GXuswQq4z/performance-test-results?orgId=1&from=now-5m&to=now&var-internal_workflow_id={test_id}" formatted_url = static_url.format(test_id=test_id) response = requests.get(url+formatted_url) short_url = response.text status_statistics = self.__result_db_handler.get_existing_tests_status_summary() return f"Tests Queue Statistics:\nNumber of tests in QUEUE:{status_statistics['queue']} \nNumber of tests SCHEDULED:{status_statistics['scheduled']} \nNumber of tests STARTING:{status_statistics['starting']} \nNumber of tests IN_PROGRESS:{status_statistics['in_progress']} \nURL to Grafana Dashboard:{short_url}" Revise this code and write in better way
Editor is loading...
Leave a Comment