fix topic spec
This commit is contained in:
parent
53d4beddec
commit
bfdce21a66
2 changed files with 4 additions and 5 deletions
|
@ -84,8 +84,8 @@ ActiveRecord::Schema.define(version: 20170209215911) do
|
|||
t.integer "user_id"
|
||||
t.string "followed_type"
|
||||
t.integer "followed_id"
|
||||
t.datetime "created_at", null: false
|
||||
t.datetime "updated_at", null: false
|
||||
t.datetime "created_at", null: false
|
||||
t.datetime "updated_at", null: false
|
||||
t.index ["followed_type", "followed_id"], name: "index_follows_on_followed_type_and_followed_id", using: :btree
|
||||
t.index ["user_id"], name: "index_follows_on_user_id", using: :btree
|
||||
end
|
||||
|
|
|
@ -3,12 +3,11 @@ require 'rails_helper'
|
|||
|
||||
RSpec.describe TopicsController, type: :controller do
|
||||
let(:user) { create(:user) }
|
||||
let(:topic) { create(:topic, user: user) }
|
||||
let(:topic) { create(:topic, user: user, updated_by: user) }
|
||||
let(:valid_attributes) { topic.attributes.except('id') }
|
||||
let(:invalid_attributes) { { permission: :invalid_lol } }
|
||||
before :each do
|
||||
sign_in :user
|
||||
|
||||
sign_in(user)
|
||||
end
|
||||
|
||||
describe 'POST #create' do
|
||||
|
|
Loading…
Reference in a new issue