Sha256: d801b2ed116b78420813fe1c593fc2b2380595fda0c16933d6ed0c9c1730af2a

Contents?: true

Size: 1.32 KB

Versions: 11

Compression:

Stored size: 1.32 KB

Contents

require 'test_helper'

module Vedeu

  describe Launcher do

    let(:described) { Vedeu::Launcher }
    let(:instance)  { described.new }

    before do
      Configuration.stubs(:configure)# .returns(test_configuration)
      Application.stubs(:start)
      Kernel.stubs(:exit)
      Kernel.stubs(:puts)
    end

    describe '#initialize' do
      it { instance.must_be_instance_of(described) }
      it { instance.instance_variable_get('@argv').must_equal([]) }
      it { instance.instance_variable_get('@stdin').must_equal(STDIN) }
      it { instance.instance_variable_get('@stdout').must_equal(STDOUT) }
      it { instance.instance_variable_get('@stderr').must_equal(STDERR) }
      it { instance.instance_variable_get('@kernel').must_equal(Kernel) }
      it { instance.instance_variable_get('@exit_code').must_equal(1) }
    end

    describe '#debug_execute!' do
      subject { instance.debug_execute! }

      context 'when debugging is enabled in the configuration' do
        # @todo
        # it { skip }
      end

      context 'when debugging is not enabled in the configuration' do
        # @todo
        # it { skip }
      end
    end

    describe '#execute!' do
      subject { instance.execute! }

      it 'returns 0 for successful execution' do
        subject.must_equal(0)
      end
    end

  end # Launcher

end # Vedeu

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
vedeu-0.4.61 test/lib/vedeu/launcher_test.rb
vedeu-0.4.60 test/lib/vedeu/launcher_test.rb
vedeu-0.4.59 test/lib/vedeu/launcher_test.rb
vedeu-0.4.58 test/lib/vedeu/launcher_test.rb
vedeu-0.4.57 test/lib/vedeu/launcher_test.rb
vedeu-0.4.56 test/lib/vedeu/launcher_test.rb
vedeu-0.4.55 test/lib/vedeu/launcher_test.rb
vedeu-0.4.54 test/lib/vedeu/launcher_test.rb
vedeu-0.4.53 test/lib/vedeu/launcher_test.rb
vedeu-0.4.52 test/lib/vedeu/launcher_test.rb
vedeu-0.4.51 test/lib/vedeu/launcher_test.rb