The running application can be found here: untwitter.herokuapp.com/
The application is rails 4 using PG for the database. It’s currently based around the index page which lists all messages. User profile pages exist (click a user’s username in the timeline)
To create the databases and the first user record, required for the application to work.
$ rake db:create $ rake db:migrate
Bundle and run the server
$ bundle (for instructions on capybara-webkit issues: https://github.com/thoughtbot/capybara-webkit/wiki/Installing-Qt-and-compiling-capybara-webkit) $ rails s
The tests use Rspec and Capybara
Capybara uses Webkit for the JS. To install this follow these instructions: github.com/thoughtbot/capybara-webkit/wiki/Installing-Qt-and-compiling-capybara-webkit
Run tests with:
$ bundle exec rake
Tests check for:
-
Valid message controller behaviour
-
Valid message model behaviour
-
Post message feature working correctly
-
Delete message feature working correctly
-
Show message feature working correctly
Further details in the test files themselves.
Core user stories
As a user:
-
I should be able to post a message to the timeline
-
I should be able to see all messages on the timeline
-
I should be able to delete a message from the timeline
Root is messages#index
A user has a username and has many messages
A message has a message body and belongs to user
There is a user created by migration “add_user1_to_users” which should be removed if the application moves to having real users.