Sha256: b47a2fd77382656274107e035c6bcbb97d2718f232ed63afc3f3aace266af0c9

Contents?: true

Size: 823 Bytes

Versions: 7

Compression:

Stored size: 823 Bytes

Contents

require 'spec_helper'
require 'earth/industry/naics_2002_naics_2007_concordance'

describe Naics2002Naics2007Concordance do
  let(:n2n) { Naics2002Naics2007Concordance }
  
  describe '.extract_note(description)' do
    it "extracts a paranthetical note from a description" do
      n2n.extract_note("Internet Service Providers - Internet services providers providing services via client-supplied telecommunications connection").
        should == "Internet services providers providing services via client-supplied telecommunications connection"
    end
  end
  
  describe 'Sanity check', :sanity => true do
    it 'should have all the data' do
      n2n.count.should == 1200
    end
    
    # spot check
    it { n2n.where(:naics_2002_code => '111219').map(&:naics_2007_code).should == ['111219', '111211'] }
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
earth-1.2.1 spec/earth/industry/naics_2002_naics_2007_concordance_spec.rb
earth-1.1.2 spec/earth/industry/naics_2002_naics_2007_concordance_spec.rb
earth-1.1.1 spec/earth/industry/naics_2002_naics_2007_concordance_spec.rb
earth-1.1.0 spec/earth/industry/naics_2002_naics_2007_concordance_spec.rb
earth-1.0.3 spec/earth/industry/naics_2002_naics_2007_concordance_spec.rb
earth-1.0.2 spec/earth/industry/naics_2002_naics_2007_concordance_spec.rb
earth-1.0.1 spec/earth/industry/naics_2002_naics_2007_concordance_spec.rb