-
-
Notifications
You must be signed in to change notification settings - Fork 156
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Test failures on 32bit node - issues with timestamps #208
Comments
That's weird. When you say 32bit node versions, what do you mean exactly? Is that on a 32-bit OS? What is the filesystem type? Etc. |
The test machines are running 64 bit OS's, I'm running the 32-bit and 64-bit node binaries, i.e - https://nodejs.org/dist/v4.5.0/node-v4.5.0-linux-x86.tar.xz Filesystems are ext4. As I say I can run both versions of node on the same machine/environment and the 32bit version throws up this odd error. |
For updated tests, see #208 (comment)
Tested Node.js versions:
Results:
Conclusion:
I suggest rewriting the test cases, change expect(futimesSpy.calls.length).toEqual(1);
expect(stats.mtime.getTime())
.toEqual(mtime.getTime()); // stats.mtime drifts in Node.js@v4.5.0-x86 into expect(futimesSpy.calls.length).toEqual(1);
expect(futimesSpy.calls[0].arguments[2].getTime())
.toEqual(mtime.getTime()); // check args instead |
Linked @OpenGG's research to citgm. |
After digging a little more, and put up a test across major Node.js versions, conclusion:
This issue roots in As for the testing code, rewriting the cases as I mentioned above should be fine. |
Also related: jprichardson/node-fs-extra#269 (comment) |
@OpenGG Just to be clear, this might happen on x64 archs but only when node is running 32-bit, correct? Otherwise the division by 1000 should not cause loss of precision (on the order of milliseconds). I think your suggested changes to vfs tests make sense, checking the arguments is enough to establish that we're at least asking @phated Does this sound reasonable? |
@erikkemperman both of those things sound completely reasonable. Want to tackle it? |
…ead of `fs.lstats().mtime` (fixes gulpjs#208)
Thanks again @OpenGG! |
…nts instead of filesystem times (fixes #208)
…nts instead of filesystem times (fixes gulpjs#208)
…nts instead of filesystem times (fixes #208)
…nts instead of filesystem times (fixes #208)
…nts instead of filesystem times (fixes #208)
…nts instead of filesystem times (fixes #208)
…nts instead of filesystem times (fixes #208)
…nts instead of filesystem times (fixes #208)
…nts instead of filesystem times (fixes #208)
…nts instead of filesystem times (fixes #208)
…nts instead of filesystem times (fixes #208)
…nts instead of filesystem times (fixes #208)
…nts instead of filesystem times (fixes #208)
…nts instead of filesystem times (fixes #208)
…nts instead of filesystem times (fixes #208)
…nts instead of filesystem times (fixes #208)
…nts instead of filesystem times (fixes #208)
…nts instead of filesystem times (fixes #208)
…nts instead of filesystem times (fixes #208)
Running the test suite via npm test on 32bit node versions is failing on -
They all fail in a similar way - which is a difference in the expected vs the actual timestamp, for example -
Running the 64bit version of node on the same machine passes the tests. Is this expected to pass on 32bit ?
The text was updated successfully, but these errors were encountered: