spec/dummy/app/controllers/posts_controller.rb in context_exposer-0.1.0 vs spec/dummy/app/controllers/posts_controller.rb in context_exposer-0.3.0
- old
+ new
@@ -1,12 +1,11 @@
class PostsController < ApplicationController
include ContextExposer::BaseController
- exposed(:post) { 'A post '}
+ exposed(:post) { Post.find 1 }
+ exposed(:posts) { Post.all }
- exposed(:posts) { ['A post ', 'Another post'] }
-
- def show
+ def show
end
def index
end
end
\ No newline at end of file