Sha256: f8c8ae89b30dbc7557c8916b34c1c807509a9e4bbb060b41bbbb793455ebd2a4

Contents?: true

Size: 1.02 KB

Versions: 4

Compression:

Stored size: 1.02 KB

Contents

require_relative '../../spec_helper'

require_relative '../../../lib/rley/gfg/start_vertex'
require_relative '../../../lib/rley/gfg/end_vertex'

# Load the class under test
require_relative '../../../lib/rley/gfg/scan_edge'

module Rley # Open this namespace to avoid module qualifier prefixes
  module GFG # Open this namespace to avoid module qualifier prefixes
    describe Edge do
      let(:vertex1) { StartVertex.new('from') }
      let(:vertex2) { StartVertex.new('to') }
      let(:sample_terminal) { double('fake-terminal') }
      subject { ScanEdge.new(vertex1, vertex2, sample_terminal) }

      context 'Initialization:' do
        it 'should be created with two vertice arguments & a terminal' do
          expect { ScanEdge.new(vertex1, vertex2, sample_terminal) }.not_to raise_error
        end
        
        it 'should know the related terminal' do
          expect(subject.terminal).to eq(sample_terminal)
        end
      end # context
    end # describe
  end # module
end # module

# End of file

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
rley-0.3.04 spec/rley/gfg/scan_edge_spec.rb
rley-0.3.01 spec/rley/gfg/scan_edge_spec.rb
rley-0.3.00 spec/rley/gfg/scan_edge_spec.rb
rley-0.2.15 spec/rley/gfg/scan_edge_spec.rb