* refactored given steps
* refactored some when stepa
* refactored remaining when and then steps
* use of when step for the action
* changed line no in expected failure
* remove and add same kind of steps in the scenario and refactored function names
* adressing reviews