changed junit test cases and UI changes

this pull request contains some 
change in the junit test cases and code 
along with some minor UI changes