Skip to content

Commit

Permalink
fixing test
Browse files Browse the repository at this point in the history
  • Loading branch information
stbnrivas committed Jul 13, 2021
1 parent e3ba37f commit 53f5b08
Show file tree
Hide file tree
Showing 9 changed files with 9 additions and 37 deletions.
7 changes: 0 additions & 7 deletions test/fixtures/gobierto_cms/section_items.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,4 @@ cms_section_madrid_1_item_b:
item_id: cookies_page
level: 0

# cms_section_madrid_1_item_b:
# item: consultation_faq (GobiertoCms::Page)
# position: 0
# parent_id: nil
# section: cms_section_madrid_1
# level: 0

<%= ERB.new(IO.read(Rails.root.join "test/fixtures_archive/gobierto_cms/section_items/santander/other.yml")).result %>
22 changes: 0 additions & 22 deletions test/fixtures/gobierto_common/collection_items.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,28 +31,6 @@ about_draft_on_site:
container: madrid (Site)



# how_to_participate
how_to_participate_participation_pages:
collection: participation_pages
item: how_to_participate
item_type: 'GobiertoCms::Page'
container: madrid (Site)

# about_participation
about_participation_on_site:
collection: site_pages
item: about_participation
item_type: 'GobiertoCms::Page'
container: madrid (Site)

# about_participation_details
about_participation_details_on_site:
collection: site_pages
item: about_participation_details
item_type: 'GobiertoCms::Page'
container: madrid (Site)

# site news
site_news_1_on_site:
collection: site_news
Expand Down
3 changes: 2 additions & 1 deletion test/forms/gobierto_admin/gobierto_cms/section_form_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
module GobiertoAdmin
module GobiertoCms
class SectionFormTest < ActiveSupport::TestCase

def valid_section_form
@valid_section_form ||= SectionForm.new(
site_id: site.id,
Expand All @@ -22,7 +23,7 @@ def invalid_section_form
end

def section
@section ||= gobierto_cms_sections(:participation)
@section ||= gobierto_cms_sections(:cms_section_madrid_1)
end

def site
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ def test_send_message_as_anonymous_user
assert_equal ["[email protected]"], email.from
assert_equal ["[email protected]"], email.reply_to
assert_equal [person.email], email.to
assert_equal "You have received a new message from Transparencia y Participación", email.subject
assert_equal "You have received a new message from Transparencia y Participción", email.subject
end
end

Expand Down Expand Up @@ -81,7 +81,7 @@ def test_send_message_as_logged_user
assert_equal [user.email], email.reply_to
assert_equal [user.email], email.reply_to
assert_equal [person.email], email.to
assert_equal "You have received a new message from Transparencia y Participación", email.subject
assert_equal "You have received a new message from Transparencia y Participción", email.subject
end
end
end
Expand Down
2 changes: 1 addition & 1 deletion test/mailers/gobierto_people/person_mailer_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ def test_new_message
assert_equal ["[email protected]"], email.from
assert_equal ["[email protected]"], email.reply_to
assert_equal [person.email], email.to
assert_equal "You have received a new message from Transparencia y Participación", email.subject
assert_equal "You have received a new message from Transparencia y Participción", email.subject
end
end
end
2 changes: 1 addition & 1 deletion test/models/gobierto_cms/page_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ def site_page
end

def module_page
@module_page ||= gobierto_cms_pages(:how_to_participate)
@module_page ||= gobierto_cms_pages(:privacy)
end

def attachable_without_attachment
Expand Down
2 changes: 1 addition & 1 deletion test/models/gobierto_cms/section_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

class SectionTest < ActiveSupport::TestCase
def section
@section ||= gobierto_cms_sections(:cms_section_madrid)
@section ||= gobierto_cms_sections(:cms_section_madrid_1)
end

def test_valid
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def subject
end

def section
@section ||= gobierto_cms_sections(:participation)
@section ||= gobierto_cms_sections(:cms_section_madrid_1)
end

def admin
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def subject
end

def section_item
@section_item ||= gobierto_cms_section_items(:participation_items)
@section_item ||= gobierto_cms_section_items(:cms_section_madrid_1_item_a)
end

def admin
Expand Down

0 comments on commit 53f5b08

Please sign in to comment.