-
Notifications
You must be signed in to change notification settings - Fork 1
How to use?
Soham Bhagwan Patel edited this page Feb 27, 2024
·
1 revision
- When you run the preventativetestframework jar, you will see the following page
- For this kind of test, please select "Preventative Test, Parallel Execution : Start Testing" Option
- Once you select the option above, you will be navigated to another ui which looks like below, please fill the valid input and start working on the same
Please enter the URL which you want to test and for config properties, we have uploaded the sample config.properties in the same repo at https://github.com/sohambpatel/PreventativeTests/blob/main/preventativetestframework/Inputs/config.properties
- Click on the Start button to start your test
- If you dont provide the config properties or you provide incorrect config properties, you will get following error which is expected
- If you dont provide the valid URL, you will again get another error which is also expected and as follows
- Please make sure you run the ZAP before you start testing, otherwise you will get the proxy error which is also expected as you havent started ZAP and browser proxy is set to it as per config properties
- Upon entering both the inputs properly, browser instance will be opened and you can start testing on the same browser instance
- Once you are done executing the scenarios, click on stop button which will create 4 files in your downloads folder, JS/consolelogs/performancelogs and security_zap_report.html
- If you want also recommendations from LLM which we are using right now chatgpt 3.5, you can hit the Get Recommendation button and same recommendations files will be created
- When you run the preventativetestframework jar, you will see the following page
- For this kind of test, please select "Preventative Test, Finalizing Test Suite Based on Synthetic App Monitoring" Option
- Upon selecting the above option you will get another screen as follows
- Please provide 3 inputs, 1. Synthetic App monitoring Output file path, sample is provided here 2. Enter the json path which will be till your exception hierarchy in the json like "$.exceptions[].exception", please notice that exception is an array and we have just given [] to it so that logic will pick parent and children separately, please use Json path Evaluater if you have any doubt and Test Repo Path for which the sample is given Sample Test Repo
- if you dont enter "Synthetic App Monitoring Output File Path" or "Enter Json Path", you will get following error accordingly which is expected
- Upon successful execution of above, 2 files will be saved in your downloads folder 1. classname.txt 2. methodname.txt, these files are generated after parsing the exceptions from the synthetic app monitoring output
- If you dont provide Test Repo Path and hit the Get Test Cases button, you will following error which is expected
- We have provided sample test repo Sample test repo
- If these files are empty or not present, we have triggered a console logs, please monitor the same
- After successful execution of above, you will get finalisedtestcases.txt file generated in your downloads folder which has test case paths
- This works based on the code coverage information added into tests so this is prerequisite, all the test cases should have code coverage information attached to them like class name and method name