Name Description Size
are_dependencies_completed.py 1722
builder
copy.sh 292
get-secret.py 3071
lib
lint
misc
run-task 36642
slack_notifier.py This module provides functionalities for sending notifications to Slack channels, specifically designed for use in automated testing and release processes. It includes capabilities for sending both success and error notifications with customizable message templates. The module leverages Taskcluster for notification services and integrates with Slack's API to deliver real-time updates. Key Features: - SLACK_SUCCESS_MESSAGE_TEMPLATE: A predefined template for formatting success messages to be sent to Slack. This template includes placeholders for dynamic content such as product version and release details. - SLACK_ERROR_MESSAGE_TEMPLATE: A template for error messages, used to notify about failures or issues in automated processes, particularly with TestRail API interactions. - send_slack_notification: A function that sends a Slack notification based on a provided template and value dictionary. It handles the construction of the message payload and interfaces with Taskcluster's Slack notification service. - get_taskcluster_options: Retrieves configuration options for Taskcluster based on the current runtime environment, ensuring appropriate setup for notification delivery. - send_error_notification: A higher-level function that formats and sends error notifications to a specified Slack channel. - send_success_notification: Similarly, this function sends success notifications to a specified Slack channel, using the success message template. Usage: The module is intended to be integrated into automated testing and release workflows, where Slack notifications are required to report the status of various processes, such as test executions or release milestones. Required Values for Notifications: These values are required when calling the `send_success_notification` and `send_slack_notification` functions. They must be passed as an object with the following keys and their respective values. Required Keys and Expected Values: - RELEASE_TYPE: <string> Release Type or Stage (e.g., Alpha, Beta, RC). - RELEASE_VERSION: <string> Release Version from versions.txt (e.g., '124.0b5'). - SHIPPING_PRODUCT: <string> Release Tag Name (e.g., fennec, focus). - TESTRAIL_PROJECT_ID: <int> Project ID for TestRail Project (e.g., Fenix Browser). - TESTRAIL_PRODUCT_TYPE: <string> Name for the official release product (e.g., Firefox, not fennec). These values are used as arguments for `success_values` and `values` when calling the respective functions. Example Usage: success_values = { "RELEASE_TYPE": "Beta", "RELEASE_VERSION": "124.0b5", "SHIPPING_PRODUCT": "fennec", "TESTRAIL_PROJECT_ID": 59, # Fenix Browser "TESTRAIL_PRODUCT_TYPE": "Firefox" } send_success_notification(success_values, 'channel_id', taskcluster_options) values = { "timestamp": time.strftime("%Y-%m-%d %H:%M:%S", time.localtime()), "error_message": error_message, } send_error_notification(values, 'channel_id', taskcluster_options) 7290
tester
testrail_main.py This Python script automates creating milestones and test runs in TestRail and updating test cases based on the results of automated smoke tests for different product releases. Functionality includes: - Reading TestRail credentials and environment variables. - Building milestone names and descriptions. - Interacting with the TestRail API to create milestones, test runs, and update test cases. - Sending notifications to a specified Slack channel. 3644
tests
write-dummy-secret.py 1042