Sha256: 9403584fd264f6fd96b821de1e2ad86325194e0b8708699ce45307e91fea9a47

Contents?: true

Size: 876 Bytes

Versions: 16

Compression:

Stored size: 876 Bytes

Contents

# frozen_string_literal: true

require_relative '../spec_helper' # Use the RSpec framework
require_relative '../../lib/mini_kraken/core/environment'

# Load the class under test
require_relative '../../lib/mini_kraken/core/variable'


module MiniKraken
  module Core
    describe Variable do
      let(:env) { Environment.new }
      subject { Variable.new('q') }

      context 'Initialization:' do
        it 'should be initialized with a name' do
          expect { Variable.new('q') }.not_to raise_error
        end

        it 'should know its name' do
          expect(subject.name).to eq('q')
        end

        it 'should be fresh by default' do
          env.add_var(subject)
          expect(subject.fresh?(env)).to be_truthy
        end
      end # context

      context 'Provided services:' do
      end # context
    end # describe
  end # module
end # module

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
mini_kraken-0.2.03 spec/core/variable_spec.rb
mini_kraken-0.2.02 spec/core/variable_spec.rb
mini_kraken-0.2.01 spec/core/variable_spec.rb
mini_kraken-0.2.00 spec/core/variable_spec.rb
mini_kraken-0.1.13 spec/core/variable_spec.rb
mini_kraken-0.1.12 spec/core/variable_spec.rb
mini_kraken-0.1.11 spec/core/variable_spec.rb
mini_kraken-0.1.10 spec/core/variable_spec.rb
mini_kraken-0.1.09 spec/core/variable_spec.rb
mini_kraken-0.1.08 spec/core/variable_spec.rb
mini_kraken-0.1.07 spec/core/variable_spec.rb
mini_kraken-0.1.06 spec/core/variable_spec.rb
mini_kraken-0.1.05 spec/core/variable_spec.rb
mini_kraken-0.1.04 spec/core/variable_spec.rb
mini_kraken-0.1.03 spec/core/variable_spec.rb
mini_kraken-0.1.02 spec/core/variable_spec.rb