middleman/middleman-sprockets — pull request #21 by bhollis (2013-04-07 03:14:31+00:00)
Title: Fix file-change tests and compatibility with latest Sprockets.

It turns out the reason the file-change tests were failing (and why all the
expire_index! calls had been added in to fix that) were because Sprockets
compares file times, and in tests, we change the same file within a second.
stat only has a resolution of 1 second on mtimes, so it didn't know the file
had changed and Sprockets wouldn't expire the cached asset. So adding in a 1
second sleep to the tests was the fix.

I removed the other expire_index! calls, and also loosened the Sprockets
version requirement and implemented the one method they require now. This lets
us track the latest Sprockets, which has some nice features like bower
component.json integration.