-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathreadme.txt
60 lines (50 loc) · 2.69 KB
/
readme.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
---------------------------------------------------
README !!!
---------------------------------------------------
On Windows (Use path separator as \ )
On UNIX (Use path separator as / )
---------------------------------------------------
ALLURE REPORT USAGES -> https://docs.qameta.io/allure-report/
ALLURE LATEST RELEASES -> https://github.com/allure-framework/allure2/releases
---------------------------------------------------
STEPS TO SETUP:
. Run command pip install -r requirements.txt
---------------------------------------------------
COMMANDS TO MANUALLY RUN TESTS AND GENERATE REPORT:
. pytest --alluredir=.\Reports\allure-results --allure-severities normal,critical
(Optional cli arguments can be used as: --browser=firefox or --browser=edge , by default --browser=chrome)
. allure generate allure-results --clean
. Run trends.bat (refer to workflow_allure.png | source: https://medium.com/testvagrant/generating-allure-trendline-on-gitlab-pages-df01c8798ae2)
---------------------------------------------------
TEST SUITE RUN:
. pytest --alluredir=.\Reports\allure-results --allure-severities normal,critical TestSuite\UI\
For First Run: (there is no historical trend data)
. Run report.py utility file.
. Run trends.bat
For Second Run: (historical trend data is available)
. Run trends.bat (to get previous run historical data)
. Run report.py utility file.
(Running with different browsers as cli options)
. pytest --alluredir=.\Reports\allure-results --allure-severities normal,critical TestSuite\UI\ --browser=firefox
. pytest --alluredir=.\Reports\allure-results --allure-severities normal,critical TestSuite\UI\ --browser=edge
---------------------------------------------------
INDIVIDUAL SUITE RUN:
. pytest --alluredir=.\Reports\allure-results --allure-severities normal,critical TestSuite\UI\HomePage\
---------------------------------------------------
TEST CASE RUN:
. pytest --alluredir=.\Reports\allure-results --allure-severities normal,critical TestSuite\UI\HomePage\test_HomePage.py::TestHomePage::test_google_feeling_lucky_feature
---------------------------------------------------
TAIL THE LIVE LOGS:
On Windows (powershell):
. cd <path-to-Reports-folder>
For Test Logs:
. Get-Content -Path .\logs\test.log -Wait
For Report Generation Logs:
. Get-Content -Path .\logs\gen_report.log -Wait
On Unix-like (console):
. cd <path-to-Reports-folder>
For Test Logs:
. tail -F ./logs/test.log
For Report Generation Logs:
. tail -F ./logs/gen_report.log
---------------------------------------------------