Change: 一般ユーザーはデフォルトで招待を不可にするよう変更 (#629)
* Change: 一般ユーザーはデフォルトで招待を不可にするよう変更 * Fix test
This commit is contained in:
parent
878b4eb2ce
commit
4119b8713e
3 changed files with 9 additions and 3 deletions
|
@ -135,12 +135,16 @@ RSpec.describe UserRole do
|
|||
end
|
||||
|
||||
it 'has default permissions' do
|
||||
expect(subject.permissions).to eq UserRole::FLAGS[:invite_users]
|
||||
expect(subject.permissions).to eq 0
|
||||
end
|
||||
|
||||
it 'has negative position' do
|
||||
expect(subject.position).to eq(described_class::NOBODY_POSITION)
|
||||
end
|
||||
|
||||
it 'is able to add invite permission' do
|
||||
expect { subject.update!(permissions: UserRole::FLAGS[:invite_users]) }.to_not raise_error
|
||||
end
|
||||
end
|
||||
|
||||
describe '.nobody' do
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue