RDK Resources
[*RDK Preferred*]
Code Management Facility
RDK Forums
[RDK Conferences]
RDK Support
Archives
Papers & Presentations Archive
Automatics is a test setup for verifying RDK builds. It can be integrated with CI flow to validate new changes checked in by user. Also, user can trigger automated tests against given RDK builds.
Automatics helps in faster release of RDK builds by validating builds using automated test execution. The results of test execution can be viewed from results page of Automatics.
Setup details will guide the user to setup Automatics system in their environment. It includes following details.
Execution Environment
-DAutomatics -DhibernateUI.config.file = {path to hibernate config file} -DloggerUI.properties.file = {path to log properties file}
./startup.sh
The system configuration page has following parameters and partner has to configure values for their environment. The description of each parameter is provided below which helps to configure them.
System Config Param | Description |
DEFAULT_SYNDICATION_PARTNER | Default syndication partner. |
SYNDICATION_PARTNERS | Syndication partner names in comma separated format |
DEVICE_INVENTORY_BASE_URL | Base URL which is having the rest implementation of device management |
EXECUTION_ENVIRONMENT_TYPES | Execution environment types in comma separated format. Supported values are RDKV, RDKB |
JUN | Jenkins Username |
JUP | Jenkins Password |
LDAP | LDAP Configuration values |
Test_Types | Test Types supported by Automatics, QUICK, 1HOUR, 4HOUR, FAST_QUICK |
EXECUTION_PRIORITY | Test cases will be executed based on the priority. Default provided values in comma separated format for execution priority are P0,P1,P2,P3 |
JOB_NAME_PREFIX | Prefix of the Jenkins job name. Default provided value is “GENERIC_RDKM_JOB” |
RDK_PORTAL_AUTH | Authentication token to access the RDK portal |
MINIMUM_FAIL_PERCENTAGE_TO_RETRY_TEST | The percentage limit to test retry the failed tests. Default provided value is 20 |
USER_DEFAULT_MODULES | Values of the default modules that can be accessed by the guest user. Default provided values separated by hyphen -3-5-6-8-9-13- |
MASTER | Comma separated string keywords to identify a build name as master |
SPRINT | Comma separated string keywords to identify a build name as sprint |
STABLE | Comma separated string keywords to identify a build name as stable |
CI_BUILD | Comma separated string keywords to identify a build name as CI build |
TM_TYPE | Automatics deployment environment. Valid values DEV or PROD |
HEAD_ENDS | Device head end values provided in comma separated format |
SERVICE_CI_VERIFICATION_VALUE | Value for service CI_VERFICATION. Supported value CI_VERIFICATION. |
SERVICE_FUNCTIONAL_VERIFICATION_VALUE | Value for service FUNCTIONAL_VERIFICATION. Supported value FUNCTIONAL _VERIFICATION. |
REASON_TYPES | Reasons for adding/updating/deleting scripts added in comma separated format |
User needs to configure all device models that is going to execute from Automatics.
Automatics identifies a device model from its build name. For this, admin user has to configure device model and its corresponding build name. It requires only to map the device model and initial starting sub string of build name.
For Automatics to use devices from partner's inventory, device groups have to be configured. The device group name in inventory should be added here so that user can execute tests on devices from configured device groups only. Admin user can map device groups to users so that only those users mapped to device group can execute tests on device.
User can configure Jenkins details in resource details. The test execution happens at jenkins.
User can configure source repository of test project in Automatics. Test project repository path and branch are passed to jenkins during execution. Jenkins will clone the repository and execute the tests. It requires user to add details from database.
For each test type in Automatics, job will be created during test execution. The jobs are created based on job templates. For each test type, a job template need to be created.
Eg: AUTO_1HOUR_JOB
Following features should be given permission only to Admin.
Upgrade Automatics
Admin can upgrade the Automatics by going to Settings -> Upgrade Automatics
Automatics provides support for automated deployment.
User Management
Admin can manage all the users of the Automatics.
Admin can Add/Delete the user details and groups. Also, manages the user group module access.
Automatics core is the base part of the system that performs the test execution. It performs following functionality
<distributionManagement>
<repository>
<url></url>
</repository>
</distributionManagement>
This project contains the generic test cases which will be executed by Automatics. The automation id and manual id in automated tests should be matching with the automation Id and manual Id present in Automatics orchestration. During test execution the execution status of each test step will be updated to Automatics orchestration. And, at the end final execution status will be updated to Automatics.
This project contains the properties as a key value pair, which will be used to run the Automatics Core/Partner Implementation/Rest Implementation Projects for executing the test cases.
Automatics system holds configuration data required for test execution in Automatics Props application.
There are two types of configuration data in Automatics Props
"partner.impl.deviceManager=true” - When set to true, Automatics expects Java based implementation of device management and it should be configured in partner-applicationContext.xml against bean "deviceProvider".
“partner.impl.powerProvider=true” - When set to true, Automatics expects Java based implementation of power provider and it should be configured in partner-applicationContext.xml against bean "powerProvider".
Automatics performs test execution in Jenkins. User can view the status of Jenkins execution from Job Manager page of Automatics. The final execution status will be updated back to Automatics.
Steps to be taken care during Jenkins configuration
Within job, in General section
filterTestIds, filterTestType, updateRdkPortal, settopList, JMD_ID, BUILD_NAME, executionMode, gr,grb
Steps to be taken care during job configuration.
In General section
pom.xml | clean install -U exec:java -DskipTests=true -DretryByDefault=false -DbuildType=RDK -Dhttps.protocols=TLSv1.1,TLSv1.2 -Dsun.security.ssl.allowUnsafeRenegotiation=true -Dautomatics.properties.file={automatics.properties.url } |
User can login into Automatics through any one of the two authentication modes. One is Self-Authentication and another is LDAP Authentication.
By giving the respective credentials such as username & password and selecting either of the Self Authentication/LDAP Authentication modes from the drop down, user can login to Automatics Tool.
User will be able to see the below Homepage after a successful login.
User can see the Builds Processed Details for a default time period of 30 days. User can change the date and click on filter to see the required details.
User can also see the Execution Details of Last 4.
To perform test execution, user needs to add test details to Automatics system. This can be done from Manage Scripts page.
Script Details
To add a new script, user can click on “Add New” link on the right top of page. Field “Automation Id” should be unique name that identifies an automated test. This id should match with the automation id in automated test case. Automatics considers RDK builds in any of the 3 categories ‘Sprint’, “Stable” and “Release”. A test case can be mapped to execute in any or all of the build types.
On Next page, Environment can be selected. In the screen shown below, the test is RDKV device related. So mapping the test against RDKV environment. Next applicable device model/s can be selected. End point “RACK_DEVICE” refers to devices managed by rack system and “DESK DEVICE” refers to desk devices. Head end field refers to device head end. If head end is provided, then during execution, Automatics can request for devices from given head end.
On Next page, user can select the feature required by device during execution of test. Here, as we are adding MOCA related test case, feature “MOCA” is selected. During execution of this test, Automatics will request for device with feature “MOCA” from inventory. If a test case can mapped to a particular RDK component testing, then it can be mapped with Field “RDK Component”. Then Click on “Save”.
Script Steps
Using filter option, display the newly added test case and click on “Update Step Details“.
We can add test steps from here and to add new step click on “Add Row” button.
After adding test steps, the scripts should be enabled. Only enabled scripts will be considered for execution by Automatics.
Tick mark shows that the script is enabled.
User can trigger a test execution from “Trigger Execution Manually” page.
Service Name “FUNCTIONAL VERIFICATION” refers to functional testing. “CI_VERIFICATION” refers to CI testing. In Build Name field, user can provide the build name that is currently loaded in device. End Point “RACK_DEVICE” and “DESK_DEVICE” which indicates Rack device and Desk device. From Environment Type, user can select values like “RDKV” or “RDKB” and test type like “1HOUR”, “4HOUR” etc.
When “Is Quick Test Required”, it means before executing tests like 1HOUR or others, an image upgrade is to be done on device. QT refers to “Quick Test” which is a special test that will load the device with image mentioned in Build Name field. Only if QT is success, other type of tests will be executed by Automatics. If QT box is unchecked, then image upgrade is not performed.
Navigate to next page. In 2nd page, user can select test cases to be executed.
Next, navigate to 3rd page Device Details. User can provide device details from here. Automatics gets devices for execution either from user or via pool based mechanism.
Select the option, ‘Specify Device MAC Address’ for user to provide the mac address. If option ‘Take Boxes from pool’ is selected, then devices will be fetched by Automatics from partner’s inventory. The device needed for execution are identified from test script features added in Manage Script page.
‘Build Appender’ field has different functions in job execution. It is used in 2 different ways.
During execution, when user provides a custom appender value, then in job manager page the jobs are displayed in separate tab with appender name. In results page, the results will be displayed in against buildname with appender so that execution results for the same build with and without appender are displayed as 2 entries.
Partner can configure pre-defined appender values in orchestration via System config. If user selects any of the pre-defined appender, then partner can add support at partner side implementation to perform device initialization based on appender value. The Automatics core sends appender to partner during initialization. This helps user to enable specific configurations in device before test execution.
When execution is triggered successfully, below pop message will be displayed.
User can verify the status of the job executions from Job Manager page. Also, user can cancel or re-trigger a job, view child jobs, navigate to Jenkins executions are other features provided by Job Manager.
Navigate to Manage Test Trigger, click on Job Manager under RDKV/RDKB.
Here, user can find the status of job executions. Quick Test(QT) is always the parent job of any other jobs. All other job types will be created under QT as child jobs. If user selected QT, then QT will be executed first on all selected devices and only when QT execution status is “COMPLETED” child jobs will start executing. If QT job status is “FAILURE”, then all child jobs become “CANCELLED”. Click on Action to view child jobs.
In scenario where user skips QT, then QT job with dummy QT test will be created and child jobs will be added under it. User can find the details of job by hovering on the job name.
Details of JOB status are
Job Status | Description |
QUEUED | Job is created and waiting for free Jenkins job for execution |
SCHEDULED | Found free Jenkins job and it is scheduled for execution |
IN PROGRESS | Jenkins job execution in progress |
CANCELLED | Jenkins job cancelled |
COMPLETED | Jenkins job execution completed successfully. The job has executed the tests. |
FAILURE | Jenkins job execution was not completed. The job has failed to executed tests. |
ALREADY_LOCKED | Device provided for execution is locked by some other execution. Execution cannot proceed. |
INVENTORY_DOWN | Device inventory is down. Automatics couldn’t get devices for execution. |
BOXES_UNUSABLE | Jenkins job execution could not be completed due to device issue |
BUILD_CHANGED_BEFORE_TEST | As pre-test verification, Automatics core will check if the build in device is same as user provided. If it is not same, then execution will fail with this status |
BUILD_CHANGED_AFTER_TEST | As post-test verification, Automatics core will check if the build in device is same as user provided. If it is not same, then execution will fail with this status |
SSH_FAIL | Automatics core will check the accessibility of device before starting test execution. If device is not accessible, then execution fails with this status |
Initially, the status will be QUEUED. When the job is triggered in Jenkins it changes to SCHEDULED and when job execution is going on, then status will become IN PROGRESS. Once, it is completed you can see the status as COMPLETED.
Action tab on the page supports features in the order as “Go To Jenkins Job”, “Re-trigger”, “View Execution Results”, “View Child Jobs” and “More Options”. User can cancel a job from “More Options”.
User will be to view and download the various reports of Build Execution Results, Device Usage, Script Health & Script Execution Time reports from the Reports section.
From execution results page, user can view the results of the triggered build executions. It shows the total count of test steps and its Pass, Fail, NT(Not Tested), NR(Not Run) and NA(Not Applicable) counts.
Now, click on Reports and go to Execution Results under RDKV/RDKB.
Following details will be displayed as shown below:
Now, click on the Build name under the Image Name column to see the Test Case Results as below.
You can verify the required information from the Execution Result Details for that particular build.
User can get an idea on the execution results from test case count via this page.
Now, click on Reports and go to Execution Results - TC under RDKV/RDKB.
Select the date for the required result details.
Following details will be displayed as shown below:
User will be able to generate the usage reports of a particular device within the required dates.
Now, click on Reports and go to Device Usage Report.
Enter the following details of Device Mac Address, Date and Time as shown below.
After the entering the details click on Generate.
The following data/details of that particular device will be generated as shown below.
User can generate the Health Report of the test scripts.
Click on Reports and go to Script Health Report.
Now, enter the following required details of Select Start Date & End Date followed by Select Category Type as shown below and click on Generate.
After clicking on Generate the following data/details will be generated as show below
Also, by clicking on Download Report you can download the report to your local in order to see the data offline.
User can generate the Execution Time Report of the test scripts for the required dates.
Click on Reports and go to Script Execution Time Report.
Now, enter the following details of Select Category Type, Select Start Date, End Date followed by Select Test Type as shown below and click on Generate.
After clicking on Generate the following data/details will be generated as show below.
Also, by clicking on Download Report you can download the report to your local in order to see the data offline.
RDK/CI portal sends execution requests to Automatics orchestration. Automatics based on filters configured decides if execution to be performed or not.
RDK E2E Manager has 2 sections.
User will be able to see the incoming RDK Requests from the RDK Portal from this page.
Navigate to RDK E2E Manager and click on E2E RDK Request under RDKV/RDKB.
If the request status is accepted, then execution will be triggered by Jenkins. Or else if the status is REJECTED, then no execution will be triggered.
User can configure RDK filters so that when request comes from RDK portal, Automatics can decide based on it, if execution should trigger or not.
Now, navigate to RDK E2E Manager and click on E2E RDK Request Filter under RDKV/RDKB.
User will be able to see the existing RDK Request Filters, if any present already like the above screen having.
We can Enable/Disable the Request Filters by clicking on the below Enable Selected Records/ Disable Selected Records. Only enabled filters will be considered by Automatics.
Also, we can show/hide the params of the request filter by clicking on Show/Hide Filter Params button above.
Edit Request Filter Details
We can Edit the Request Filter, by clicking on Edit Request Filter Details under the Action column.
Edit the required details of the request filter and click on Save Results.
Add new Request Filter Details
We can add a new Request Filter, by clicking on Add Request Filter Details button above.
Now, enter the required Settings details & Automation ID details of the filter and click on Save Results.