README.md in neo-rails-0.0.2 vs README.md in neo-rails-0.0.3
- old
+ new
@@ -1,8 +1,13 @@
-# Neo::Rails
+# Neo::Rails [](http://travis-ci.org/neopoly/neo-rails)
+`neo-rails` contains some tools helping us doing Rails.
-TODO: Write a gem description
+This gem includes:
+* Mocks
+* Presenters
+* Exposure
+* Scenarios
## Installation
Add this line to your application's Gemfile:
@@ -20,43 +25,50 @@
### Presenter
In app/presenters/presenter.rb
- class Presenter
- include Neo::Rails::Presenter
- end
+```ruby
+class Presenter
+ include Neo::Rails::Presenter
+end
+class UserPresenter < Presenter
+ def initialize(user)
+ @user = user
+ end
- class UserPresenter < Presenter
- def initialize(user)
- @user = user
- end
+ def name
+ @user.name
+ end
- def name
- @user.name
- end
+ def profile_path
+ view_context.link_to view_context.user_profile_path(@user), name
+ end
+end
+```
- def profile_path
- view_context.link_to view_context.user_profile_path(@user), name
- end
- end
-
In test/test_helper.rb
- require 'neo/rails/presenter/test_helper'
+```ruby
+require 'neo/rails/presenter/test_helper'
- Neo::Rails::Presenter::TestHelper.setup
+Neo::Rails::Presenter::TestHelper.setup
+```
### Scenarios
In app/assets/stylesheets/application.css:
+ /*= require neo-rails */
+
+In app/assets/javascript/application.js
+
//= require neo-rails
-In app/layouts/application.html.haml
+In app/layouts/application.html.erb
- = render_scenarios_list
+ <%= render_scenarios_list %>
## Contributing
1. Fork it
2. Create your feature branch (`git checkout -b my-new-feature`)