- Sessions
- Install Python
- Install common test library
- Run tests
- Demo1: Execute simple test using Standard Library
- Demo2: Execute simple test using open-source External Library is installed by
pip
- Demo3: Execute simple test using custom External Library is implemented by Python with static API
- Demo4: Execute simple test using custom External Library is implemented by Python with dynamic API
- Demo5: Execute simple test using custom External Library is implemented by Python with hybrid API
- Demo6: Execute all tests in previous demos in a single execution
- Autoformatting Robot Framework code
Switch branch to see contents of each session
Following the wiki
Refer to: https://docs.robotframework.org/docs/getting_started/testing#install-python
Check out the repository test-automation-fwk-python for common test library source. Clone the library repository to local in same level with this test repository.
Follow steps to build and install the common test library
As the instruction, you are able to install the common test library in the global environment or in the in-project virtualenv.
With using in-project virtualenv in test-automation-fwk-python. Needs to activate the virtualenv before running tests in this repo.
../test-automation-fwk-python/.venv/Scripts/activate
Based the environment you selected and install the common test library, you can proceed to the next steps to execute test. Ensure can check Robot Framework version by running the command:
robot --version
Note: ensure the terminal is in the root directory of the project
robot --include demo1 --outputdir reports ./tests
--outputdir
defines where to create output files (log.html, output.xml, report.html)
robot --include demo2 --outputdir reports ./tests
robot --include demo3 --outputdir reports ./tests
--pythonpath
additional locations to add to the module search path
robot --include demo4 --outputdir reports ./tests
robot --include demo5 --outputdir reports ./tests
robot --include session2 --outputdir reports ./tests
You are able to use any IDE to work with Robot Framework code, while compose the code you may not always can keep the
format or indent consistent. robotidy
is a tool to help you format the code once you have done.
robotidy
is tool for cleaning up and changing format of Robot Framework test data files
Mandatory argument is the path to file or a directory to format. If a directory is given, all files inside it are processed recursively.
robotidy ./tests