Sha256: ef1c155b10a316791d6bd4f600c7e4f48d5015fd69875c4e973545aa722370b7

Contents?: true

Size: 817 Bytes

Versions: 18

Compression:

Stored size: 817 Bytes

Contents

require_relative '../../spec_helper'

# Load the class under test
require_relative '../../../lib/rley/syntax/terminal'

module Rley # Open this namespace to avoid module qualifier prefixes
  module Syntax # Open this namespace to avoid module qualifier prefixes
    describe Terminal do
      let(:sample_name) { 'noun' }
      subject { Terminal.new(sample_name) }

      context 'Initialization:' do
        it 'should be created with a name' do
          expect { Terminal.new('noun') }.not_to raise_error
        end

        it 'should know its name' do
          expect(subject.name).to eq(sample_name)
        end
        
        it "should know that isn't nullable" do
          expect(subject).not_to be_nullable
        end
      end # context
    end # describe
  end # module
end # module

# End of file

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
rley-0.2.15 spec/rley/syntax/terminal_spec.rb
rley-0.2.14 spec/rley/syntax/terminal_spec.rb
rley-0.2.12 spec/rley/syntax/terminal_spec.rb
rley-0.2.11 spec/rley/syntax/terminal_spec.rb
rley-0.2.10 spec/rley/syntax/terminal_spec.rb
rley-0.2.09 spec/rley/syntax/terminal_spec.rb
rley-0.2.08 spec/rley/syntax/terminal_spec.rb
rley-0.2.06 spec/rley/syntax/terminal_spec.rb
rley-0.2.05 spec/rley/syntax/terminal_spec.rb
rley-0.2.04 spec/rley/syntax/terminal_spec.rb
rley-0.2.03 spec/rley/syntax/terminal_spec.rb
rley-0.2.02 spec/rley/syntax/terminal_spec.rb
rley-0.2.01 spec/rley/syntax/terminal_spec.rb
rley-0.2.00 spec/rley/syntax/terminal_spec.rb
rley-0.1.12 spec/rley/syntax/terminal_spec.rb
rley-0.1.11 spec/rley/syntax/terminal_spec.rb
rley-0.1.10 spec/rley/syntax/terminal_spec.rb
rley-0.1.09 spec/rley/syntax/terminal_spec.rb