1. User Interface Testing
This check list seems to catch most bugs. We are not going to automate UI testing because it's not appropriate. The application is not massive and is scheduled to be mature in another 12 months or so. Just be sure to execute all the tests therein which takes about an hour if you are adequately caffeinated and focused.
2. Unit Testing
We have a modest number of python/django unit tests.
We do not have any unit tests for the javascript code.
When to write a test?
Here is when I consider writing a unit test.
When you find a bug, try to write a test that finds it.
If you start the debugger, consider writing a unit test test instead.
This can be expensive and so it is reasonable to debate this point.
Use your judgement.
Often writing a test is super easy and very much helps to prevent regressions.
Running the Unit Tests
From the command line run
https://bitbucket.org/sfgovdt/eas/src/default/web/run_tests.cmd
which goes through the settings.py and calls into
https://bitbucket.org/sfgovdt/eas/src/default/web/test_suites.cmd
3. Testing the Change Notification Emails
- Begin by confirming that you are a recipient of the Change Notification emails.
- See config_notifications.py in /automation/src/config/live/ and check/modify variables devAddressChangeNotificationEmails and/or prodAddressChangeNotificationEmails so that they include your email address.
- For environments SF_DEV and SF_QA see the devAddressChangeNotificationEmails variable. For environments SF_PROD and SD_PROD see the prodAddressChangeNotificationEmails variable.
- Connect to a Windows automation server (SF_DEV, SF_QA, SF_PROD or SD_PROD) using Microsoft Remote Desktop.
- Open 'Command Prompt' and change to the folder containing the change notification script https://bitbucket.org/sfgovdt/eas/src/default/automation/src/job.py
C:\apps\eas_automation\automation\src
- Run the address_change_report job:
python job.py --env ENVIRONMENT --job address_change_report --action EXECUTE --v
- Substitute ENVIRONMENT with one of the relevant environments: SF_DEV, SF_QA, SF_PROD, SD_PROD
- Run the address_change_notification job:
python job.py --env ENVIRONMENT --job address_change_notification --action EXECUTE --v
- Substitute ENVIRONMENT with one of the relevant environments: SF_DEV, SF_QA, SF_PROD, SD_PROD
- Check your email inbox to confirm that the change notifications emails were received.
- If applicable, revert any temporary changes to config_notifications.py made in Step 1.
0 Comments