Hi:
The error code reported, Hard Disk 1 Full Test Failure, means the hard drive needs to be replaced and the operating system reinstalled.
If you can still get into windows, back up any files you need to save onto a portable hard drive.
Below is the link to the service manual for your notebook. The HDD R & R procedure can be found in chapter 6.
http://h10032.www1.hp.com/ctg/Manual/c06147959
You may want to consider purchasing a better performing, normally more reliable solid state drive (SSD).
After you replace the hard drive, you should be able to reinstall Windows by using the cloud recovery client utility.
See this link for more info on that...
https://support.hp.com/us-en/document/c06162205