Commit b30593ff authored by Sean Arnold's avatar Sean Arnold

Fix operation helper spec

parent 538a8ecc
......@@ -23,7 +23,7 @@ module OperationsHelper
def status_page_settings_data(status_page_setting)
{
'user-can-enable-status-page' => can?(current_user, :admin_operations, @project).to_s,
'setting-enabled' => status_page_setting&.enabled?.to_s,
'setting-enabled' => status_page_setting&.enabled?&.to_s,
'setting-aws-access-key' => status_page_setting&.aws_access_key,
'setting-masked-aws-secret-key' => status_page_setting&.masked_aws_secret_key,
'setting-aws-region' => status_page_setting&.aws_region,
......
......@@ -53,7 +53,7 @@ describe OperationsHelper do
it 'returns the correct values' do
aggregate_failures do
expect(subject['user-can-enable-status-page']).to eq('true')
expect(subject['setting-enabled']).to eq(status_page_setting.enabled)
expect(subject['setting-enabled']).to eq(status_page_setting.enabled.to_s)
expect(subject['setting-aws-access-key']).to eq(status_page_setting.aws_access_key)
expect(subject['setting-masked-aws-secret-key']).to eq(status_page_setting.masked_aws_secret_key)
expect(subject['setting-aws-region']).to eq(status_page_setting.aws_region)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment