在练习中,为full_title助手编写测试,并且必须填写代码。这里是测试 require 'test_helper'
class ApplicationHelperTest < ActionView::TestCase
test "full title helper" do
assert_equal full_title, FILL_IN
assert_eq
我在rspec中有一个测试未通过,我不知道原因。测试指责以下情况: 1) SalesmenController POST #create redirect to new team
Failure/Error: params.require(:salesmen).permit(:name, :company_id)
ActionController::ParameterMiss
我对Rails有点新,我想在我的应用程序中创建用户组。用户可以属于多个组,并且组中可以有许多用户。例如,将会有一年级的所有一年级教师,他们也将属于其他一些小组。 这是我当前的代码。 class Group < ApplicationRecord
has_many :users
end
class User < ApplicationRecord
belongs_to :g