clarify page sorting test

This commit is contained in:
Aidan Feldman 2013-12-19 13:46:43 -05:00
parent a6e1c40051
commit 45ee9f814a
1 changed files with 1 additions and 3 deletions

View File

@ -154,9 +154,7 @@ class TestSite < Test::Unit::TestCase
assert_equal @site.generators.sort_by(&:class).map{|g|g.class.priority}, @site.generators.map{|g|g.class.priority}
end
should "sort pages in a consistent way" do
# The order that files are returned differs across operating systems, so ensure that they're being sorted after the fact.
# http://stackoverflow.com/a/5529966/358804
should "sort pages alphabetically" do
stub.proxy(Dir).entries { |entries| entries.reverse }
@site.process
sorted_pages = %w(.htaccess about.html bar.html contacts.html deal.with.dots.html foo.md index.html index.html sitemap.xml symlinked-file)