From 3ef60724b979c4b71e2fdba1d9ee6a9a2db35921 Mon Sep 17 00:00:00 2001 From: Lucas Melo Date: Mon, 26 Aug 2013 13:32:02 -0300 Subject: [PATCH] cms_controller: add test for mandatory fields in blog creation form --- test/functional/cms_controller_test.rb | 5 +++++ 1 file changed, 5 insertions(+), 0 deletions(-) diff --git a/test/functional/cms_controller_test.rb b/test/functional/cms_controller_test.rb index 035b0a4..64ba27f 100644 --- a/test/functional/cms_controller_test.rb +++ b/test/functional/cms_controller_test.rb @@ -932,6 +932,11 @@ class CmsControllerTest < ActionController::TestCase assert_tag :tag => 'a', :content => 'Cancel', :attributes => { :href => /\/myprofile\/#{profile.identifier}/ } end + should 'have only one mandatory field in the blog creation form' do + get :new, :profile => profile.identifier, :type => Blog.name + assert_select '.required-field .formfieldline', 1 + end + should 'create icon upload file in folder' do f = Gallery.create!(:name => 'test_folder', :profile => profile) post :new, :profile => profile.identifier, -- libgit2 0.21.2