Sha256: 79dbf03cb570af2cd180d3368eb7c94cc4871a3f5d903aaf172b5c2fa79359c8

Contents?: true

Size: 1.13 KB

Versions: 66

Compression:

Stored size: 1.13 KB

Contents

require 'spec_helper'

feature 'Choose organization Flow' do
  let!(:central) { create(:organization, name: 'central') }
  let!(:some_orga) { create(:public_organization, name: 'someorga', profile: profile) }

  let(:profile) { Mumukit::Platform::Organization::Profile.parse json  }
  let(:json) { { contact_email: 'some@email.com', locale: 'en', errors_explanations: { 404 => 'Some explanation'} } }

  scenario 'when routes does not exist in implicit central' do
    visit '/foo'

    expect(page).to have_text('You may have mistyped the address')
  end

  scenario 'when route does not exist in explicit central' do
    set_subdomain_host! 'test'

    visit '/foo'

    expect(page).to have_text('You may have mistyped the address')
  end

  scenario 'when organization does not exist' do
    set_subdomain_host! 'foo'

    visit '/'

    expect(page).to have_text('You may have mistyped the address')
  end

  scenario 'when organization has a customized error message' do
    set_subdomain_host! 'someorga'

    visit '/foo'

    expect(page).to have_text('Some explanation')
    expect(page).not_to have_text('You may have mistyped the address')
  end
end

Version data entries

66 entries across 66 versions & 1 rubygems

Version Path
mumuki-laboratory-6.7.7 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.7.6 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.7.5 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.7.4 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.7.3 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.7.2 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.7.1 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.7.0 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.6.1 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.6.0 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.5.1 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.5.0 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.4.2 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.4.1 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.4.0 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.2.0 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.1.5 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.0.4 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.1.4 spec/features/not_found_public_flow_spec.rb
mumuki-laboratory-6.1.3 spec/features/not_found_public_flow_spec.rb