Sort order in directory globs #135

Merged
tddium merged 1 commits from master into master 2012-04-03 13:50:51 +00:00
tddium commented 2012-04-03 03:45:54 +00:00 (Migrated from github.com)

Hello,

The order in which Jasmine headless webkit loads files specified on jasmine.yml is file system dependent.
On MacOS X, HFS+ guarantees that directory entries are read in sorted order (http://developer.apple.com/legacy/mac/library/#technotes/tn/tn1150.html). This is not the case with other Unix filesystems such as ext2/ext3/ext4 under Linux. The inconsistency in load order results in a test suite that works in one place (e.g. on a Mac) but the same suite fails due to load order problems in another (e.g. on a Linux box). In fact, the results can differ from one copy of a suite to another on the same Linux box depending on the sequence of file create, remove, etc. calls in each copy. A simple solution is to sort the results of expanding a directory glob so that the results are consistent across platforms.

Hello, The order in which Jasmine headless webkit loads files specified on jasmine.yml is file system dependent. On MacOS X, HFS+ guarantees that directory entries are read in sorted order (http://developer.apple.com/legacy/mac/library/#technotes/tn/tn1150.html). This is not the case with other Unix filesystems such as ext2/ext3/ext4 under Linux. The inconsistency in load order results in a test suite that works in one place (e.g. on a Mac) but the same suite fails due to load order problems in another (e.g. on a Linux box). In fact, the results can differ from one copy of a suite to another on the same Linux box depending on the sequence of file create, remove, etc. calls in each copy. A simple solution is to sort the results of expanding a directory glob so that the results are consistent across platforms.
recurser commented 2012-04-03 08:54:28 +00:00 (Migrated from github.com)

+1

+1
johnbintz commented 2012-04-03 13:50:56 +00:00 (Migrated from github.com)

Thanks!

Thanks!
Sign in to join this conversation.
No reviewers
No Label
bug
doc
feature
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: github-migration/jasmine-headless-webkit#135
No description provided.