You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: user_creates_branch_and_merge_request_spec.rb
    path of file: ./repos/gitlabhq/spec/features/issues
    
    the code of the file until where you have to start completion: # frozen_string_literal: true

require 'spec_helper'

RSpec.describe 'User creates branch and merge request on issue page', :js, feature_category: :team_planning do
  let(:membership_level) { :developer }
  let(:user) { create(:user) }
  let!(:project) { create(:project, :repository, :public) }
  let(:issue) { create(:issue, project: project, title: 'Cherry-Coloured Funk') }

  context 'when signed out' do
    before do
      visit project_issue_path(project, issue)
    end

    it "doesn't show 'Create merge request' button" do
      expect(page).not_to have_selector('.create-mr-dropdown-wrap')
    end
  end

  
    
  def test_source_checking(input_source)
    expect(input_source.value).to eq(project.default_branch)

    input_source.set('mas') # Intentionally entered first 3 letters of `master` to check autocomplete feature later.
    source_message = find('.js-ref-message')

    expect(source_message).to have_text('Checking source availability…')

    wait_for_requests

    expect(source_message).to have_text('Source is not available')

    # JavaScript gets refs started with `mas` (entered above) and places the first match.
    # User sees `mas` in black color (the part they entered) and the `ter` in gray color (a hint).
    # Since hinting is implemented via text selection and rspec/capybara doesn't have matchers for it,
    # we just checking the whole source name.
    expect(input_source.value).to eq(project.default_branch)
  end
end