Write a test suite that validates the data contained in the file (https://raw.githubusercontent.com/SouthbankSoftware/SBSPublic/master/JStesterTestData.json).
The test suite can be written in a Javascript framework of your choice or as native Javascript code. It should be runnable in nodeJS: we'll try and run it against 8.9.1. You should include a package.json file that contains any dependencies.
The test suite should accept the file name from the command line, an environment variable or a configuration file.
There are three test cases to write:
- The case sensitive value of the proofType attribute should be "full" or "incremental."
- The date value in submitTimestamp should be no ealier than one year ago
- The value of the Country attribute should be a valid country code. Use the rest service at (http://services.groupkt.com/country/get/iso3code) to validate this
Using framework you like, write a test case that checks the following:
- The website http://wwww.dbkoda.com is reachable.
- The Download link at the top of the page navigates to the downloads section,
- Clicking on the Windows download button causes 'dbkoda-latest.exe' to be downloaded.
- The "Subscribe" button is visible
- Clicking subscribe brings up the username/email dialogue
- The email field rejects obviously incorrect emails (ones not containing an "@" symbol for instance.