Skip to content

Commit

Permalink
Adds a test to explore relative rank position.
Browse files Browse the repository at this point in the history
  • Loading branch information
dceades committed Oct 14, 2013
1 parent 13886a1 commit 4d32861
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions spec/models/nomenclatural_rank_spec.rb
Expand Up @@ -2,6 +2,15 @@

describe NomenclaturalRank do

context 'David' do
specify 'ranks should have an integer index' do
rank_class = Ranks.lookup(:iczn, 'family')
rank_class2 = Ranks.lookup(:iczn, 'genus')
expect(RANKS.index(rank_class).class).to eq(Fixnum)
expect(RANKS.index(rank_class) < RANKS.index(rank_class2)).to be_true
end
end

context 'base methods' do
specify "rank_name" do
expect(NomenclaturalRank).to respond_to(:rank_name)
Expand Down

0 comments on commit 4d32861

Please sign in to comment.