scaffold models
This commit is contained in:
25
spec/views/settings/zones/index.html.erb_spec.rb
Normal file
25
spec/views/settings/zones/index.html.erb_spec.rb
Normal file
@@ -0,0 +1,25 @@
|
||||
require 'rails_helper'
|
||||
|
||||
RSpec.describe "settings/zones/index", type: :view do
|
||||
before(:each) do
|
||||
assign(:settings_zones, [
|
||||
Settings::Zone.create!(
|
||||
:name => "Name",
|
||||
:is_active => false,
|
||||
:created_by => "Created By"
|
||||
),
|
||||
Settings::Zone.create!(
|
||||
:name => "Name",
|
||||
:is_active => false,
|
||||
:created_by => "Created By"
|
||||
)
|
||||
])
|
||||
end
|
||||
|
||||
it "renders a list of settings/zones" do
|
||||
render
|
||||
assert_select "tr>td", :text => "Name".to_s, :count => 2
|
||||
assert_select "tr>td", :text => false.to_s, :count => 2
|
||||
assert_select "tr>td", :text => "Created By".to_s, :count => 2
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user