Ensure that you have metamask plugin install on your browser.
Go the development.js (BackEnd/development.js) and change the address in accounts[0] to your own address. You would now the the owner of the contract. Note that, the values you change it to has to be lowercase. E.g. if the address in your metamask account has a hexadecimal 'E', you have to change it to 'e' when entering it into the development.js file.
Change the addresses in accounts (e.g. accounts[1], accounts[2] and so on) to accounts that you would like to test. These accounts should be existing accounts in your metamask browser plug in.
Test case 1: Using BlockLife as an institution
As the owner, first log into BlockLife, then register the institution's address, using the "Register Institution" form.
If you would like this institution to be a CA as well, please do so, using the "Register CA" form.
Now, switch your metamask address to the registered institution's address, and log in as an institution.
Test case 2: Using BlockLife as an individual
Simply log in using any metamask address, that has not been registered as an institution or contract owner.
npm install -g truffle
npm install -g ganache-cli
Once done, run the following command to deploy blockchain server (default at 127.0.0.1:8545)
ganache-cli --seed IS4302 -e 10000000000000 -l 80000000 // do not close
cd BackEnd npm install @openzeppelin/contracts // to download and install dependencies
truffle migrate // to compile and deploy the contracts on the server
Go to the BackEnd folder and install the required packages (Express server will be deployed at port 3000)
cd BackEnd && npm install
nodemon www // do not close
Go to the FrontEnd folder and install the required packages (Deployed at http://localhost:8100/)
cd FrontEnd && npm install
npm i @angular-devkit/build-angular@0.803.24 //to avoid an error
ionic serve // do not close