spec测试问题

在测试spec/controller文件时,后台的private方法,我使用跟以action提交方式的方法去测试,我本机不报错,但是同事的报错,错误如下:

ActionController::UnknownAction in 'ConfigurationsController GET 'set_departments''
No action responded to set_departments. Actions: check_permission, check_special_permission, condition, img_size, index, local_request?, log_exception, m, must_login, params_condition, per_page, rescue_action_in_public, save_levels, save_main, search_condition, selected_district, selected_district_name, set_configuration_departments, set_menu, set_online_user, top, and workitem_attributes_from
/home/liweihui/.gem/ruby/1.8/gems/haml-2.0.10/lib/sass/plugin/rails.rb:19:in `process'
./spec/controllers/configurations_controller_spec.rb:30:

这是为什么?

1个回答

信息不太够,问题没解决的话把controller代码和spec代码贴上来看看吧
胡猜一个的话 环境一样吗?
gem list一样吗?

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
立即提问