fix indexing and ordering for section and card
This commit is contained in:
@ -13,5 +13,14 @@ module Merged
|
||||
it "has index" do
|
||||
expect(first.index).to eq 1
|
||||
end
|
||||
|
||||
it "first has no previous" do
|
||||
expect(first.index).to be 1
|
||||
expect(first.previous_card).to be nil
|
||||
end
|
||||
it "first has next" do
|
||||
expect(first.next_card.index).to be 2
|
||||
end
|
||||
|
||||
end
|
||||
end
|
||||
|
@ -18,7 +18,7 @@ module Merged
|
||||
end
|
||||
it "has section indexes" do
|
||||
index.sections.each_with_index do |section, index|
|
||||
expect(section.index).to be index + 1
|
||||
expect(section.index).to be index + 1 # because we have human index
|
||||
end
|
||||
end
|
||||
end
|
||||
|
Reference in New Issue
Block a user