8c42a0eac0
Using the sed script from https://gitlab.com/gitlab-org/gitlab-ce/issues/59758
18 lines
436 B
Ruby
18 lines
436 B
Ruby
# frozen_string_literal: true
|
|
|
|
require 'spec_helper'
|
|
|
|
describe Gitlab::Middleware::ReleaseEnv do
|
|
let(:inner_app) { double(:app, call: 'yay') }
|
|
let(:app) { described_class.new(inner_app) }
|
|
let(:env) { { 'action_controller.instance' => 'something' } }
|
|
|
|
describe '#call' do
|
|
it 'calls the app and clears the env' do
|
|
result = app.call(env)
|
|
|
|
expect(result).to eq('yay')
|
|
expect(env).to be_empty
|
|
end
|
|
end
|
|
end
|