2019-10-17 02:07:30 -04:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2018-01-16 16:13:14 -05:00
|
|
|
require 'spec_helper'
|
|
|
|
|
2020-06-16 14:09:01 -04:00
|
|
|
RSpec.describe 'Groups (JavaScript fixtures)', type: :controller do
|
2018-01-16 16:13:14 -05:00
|
|
|
include JavaScriptFixturesHelpers
|
|
|
|
|
2020-12-07 07:10:00 -05:00
|
|
|
let(:user) { create(:user) }
|
2019-02-21 11:54:28 -05:00
|
|
|
let(:group) { create(:group, name: 'frontend-fixtures-group', runners_token: 'runnerstoken:intabulasreferre')}
|
2018-01-16 16:13:14 -05:00
|
|
|
|
|
|
|
before(:all) do
|
|
|
|
clean_frontend_fixtures('groups/')
|
|
|
|
end
|
|
|
|
|
|
|
|
before do
|
2020-12-07 07:10:00 -05:00
|
|
|
group.add_owner(user)
|
|
|
|
sign_in(user)
|
2018-01-16 16:13:14 -05:00
|
|
|
end
|
|
|
|
|
2020-12-07 07:10:00 -05:00
|
|
|
render_views
|
|
|
|
|
2018-10-15 09:36:19 -04:00
|
|
|
describe GroupsController, '(JavaScript fixtures)', type: :controller do
|
2019-04-21 06:58:07 -04:00
|
|
|
it 'groups/edit.html' do
|
2018-12-19 14:50:20 -05:00
|
|
|
get :edit, params: { id: group }
|
2018-10-15 09:36:19 -04:00
|
|
|
|
2019-07-17 18:15:53 -04:00
|
|
|
expect(response).to be_successful
|
2018-10-15 09:36:19 -04:00
|
|
|
end
|
|
|
|
end
|
2018-01-16 16:13:14 -05:00
|
|
|
end
|