Sha256: c7092edea2c3c2a622abb748485caba834b0c5dda7deb65b0e42fb05ce3437d2

Contents?: true

Size: 624 Bytes

Versions: 3

Compression:

Stored size: 624 Bytes

Contents

require 'spec_helper'
require 'guard'

module RevealCK
  module Commands
    describe ListenToReloadBrowser do
      describe '#run' do
        it 'works with Guard to setup livereload' do
          serve_ui = double

          expect(serve_ui)
            .to(receive(:prefix_for))
            .and_return('[prefix]')

          expect(::Guard)
            .to(receive(:start))
            .once

          listen_to_reload_browser = ListenToReloadBrowser.new(serve_ui)
          listen_to_reload_browser.run

          expect(Guard::UI.options[:template]).to eq '[prefix] :message'
        end
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
reveal-ck-3.0.0 spec/lib/reveal-ck/commands/listen_to_reload_browser_spec.rb
reveal-ck-0.6.2 spec/lib/reveal-ck/commands/listen_to_reload_browser_spec.rb
reveal-ck-0.6.1 spec/lib/reveal-ck/commands/listen_to_reload_browser_spec.rb