Sha256: c838ea86cd11680f7633f2e2f307d64f2365a8f8b3c8522877a8f1543f673aec
Contents?: true
Size: 486 Bytes
Versions: 26
Compression:
Stored size: 486 Bytes
Contents
require "rails_helper" RSpec.describe "posts/index", type: :view do let(:posts) { [create(:post, title: "Title", body: "Body"), create(:post)] } before(:each) do assign(:posts, posts) end it "renders a list of posts" do render assert_select "tr>td", text: "Title", count: 1 assert_select "tr>td", text: "Body", count: 1 assert_select "tr>td", text: "This is a post", count: 1 assert_select "tr>td", text: "It has a lot of content", count: 1 end end
Version data entries
26 entries across 26 versions & 1 rubygems