how to write test cases in real time