refactor code and add test for app
change the grammar of rspec in the test for app
update readme