Sha256: 1d73967f5af5e4d07c50d2cca3bd6d12b99c182e0013261a194765fe8e14ebd3

Contents?: true

Size: 675 Bytes

Versions: 17

Compression:

Stored size: 675 Bytes

Contents

require 'spec_helper'

describe 'web/views/contact.haml', :haml_view => true do

  it "should escape unsafe check characters in URI parameters" do
    @contact = mock('contact')
    @contact.should_receive(:media)
    @contact.should_receive(:name).twice.and_return('Aeschylus')
    @contact.should_receive(:notification_rules)

    entity = mock('entity')
    entity.should_receive(:name).exactly(3).times.and_return('abc-xyz-01')

    checks = ['Disk / Utilisation']

    @entities_and_checks = [{:entity => entity, :checks => checks}]

    page = render_haml('contact.haml', self)
    page.should match(%r{\?entity=abc-xyz-01&check=Disk\+%2F\+Utilisation})
  end

end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
flapjack-0.7.18 spec/lib/flapjack/gateways/web/views/contact.haml_spec.rb
flapjack-0.7.17 spec/lib/flapjack/gateways/web/views/contact.haml_spec.rb
flapjack-0.7.16 spec/lib/flapjack/gateways/web/views/contact.haml_spec.rb
flapjack-0.7.15 spec/lib/flapjack/gateways/web/views/contact.haml_spec.rb
flapjack-0.7.14 spec/lib/flapjack/gateways/web/views/contact.haml_spec.rb
flapjack-0.7.13 spec/lib/flapjack/gateways/web/views/contact.haml_spec.rb
flapjack-0.7.12 spec/lib/flapjack/gateways/web/views/contact.haml_spec.rb
flapjack-0.7.11 spec/lib/flapjack/gateways/web/views/contact.haml_spec.rb
flapjack-0.7.10 spec/lib/flapjack/gateways/web/views/contact.haml_spec.rb
flapjack-0.7.9 spec/lib/flapjack/gateways/web/views/contact.haml_spec.rb
flapjack-0.7.8 spec/lib/flapjack/gateways/web/views/contact.haml_spec.rb
flapjack-0.7.7 spec/lib/flapjack/gateways/web/views/contact.haml_spec.rb
flapjack-0.7.6 spec/lib/flapjack/gateways/web/views/contact.haml_spec.rb
flapjack-0.7.5 spec/lib/flapjack/gateways/web/views/contact.haml_spec.rb
flapjack-0.7.4 spec/lib/flapjack/gateways/web/views/contact.haml_spec.rb
flapjack-0.7.3 spec/lib/flapjack/gateways/web/views/contact.haml_spec.rb
flapjack-0.7.2 spec/lib/flapjack/gateways/web/views/contact.haml_spec.rb