└── README.md /README.md: -------------------------------------------------------------------------------- 1 | # How to add custom metadata to automation tests in UnitTest on [LambdaTest](https://www.lambdatest.com/?utm_source=github&utm_medium=repo&utm_campaign=UnitTest-custom-metadata) 2 | 3 | If you want to add custom metadata to automation tests in UnitTest on LambdaTest, you can follow the steps below. You can refer to sample test repo [here](https://github.com/LambdaTest/Python-UnitTest-Selenium). 4 | 5 | # Steps 6 | With LambdaTest, you can add custom meta data to automation tests. These are added for tests by setting the data in `customData` capability. The code below illustrates the usage: 7 | 8 | ```python 9 | desired_caps = { 10 | 'LT:Options': { 11 | "build": "Python Demo", # Change your build name here 12 | "name": "Python Demo Test", # Change your test name here 13 | "platformName": "Windows 11", 14 | "selenium_version": "4.0.0", 15 | "customData": [ 16 | { "_id": "5f46aaa69adf77cfe2bb4fd6", 17 | "index": "0", 18 | "guid": "9451b204-12f0-4177-8fe9-fb019b3e4bf3", 19 | "isActive": "False", 20 | "picture": "http//placehold.it/32x32" } ] 21 | }, 22 | "browserName": "Chrome", 23 | "browserVersion": "98.0", 24 | } 25 | 26 | ``` 27 | 28 | 29 | ## Run your test 30 | 31 | ```bash 32 | python lambdatest_test.py 33 | ``` 34 | 35 | # Links: 36 | 37 | [LambdaTest Community](http://community.lambdatest.com/) 38 | 39 | --------------------------------------------------------------------------------