GithubHelp home page GithubHelp logo

Comments (9)

jyurek avatar jyurek commented on July 20, 2024

There's a load order issue at work here. Requiring Tempfile after FakeFS means Tempfile's extension to Dir gets loaded onto the Fake Dir, not RealDir. Deactivating FakeFS then breaks Tempfile completely. I don't know of a way around that except to make sure FakeFS gets loaded after Tempfile. The /tmp directory itself should simply be created by a test helper or something.

from fakefs.

marano avatar marano commented on July 20, 2024

Hello,
The problem here is not the load order, it happens that FakeFS::Dir.mkdir won't work properly when the path starts with a dot.
A fix for this and other issues, at my fork http://github.com/marano/fakefs .
Cheers.

from fakefs.

smtlaissezfaire avatar smtlaissezfaire commented on July 20, 2024

Can you point me to the commit which fixes this issue?

from fakefs.

marano avatar marano commented on July 20, 2024

Sure, this is the commit marano@bc9a3f7
Thanks.

from fakefs.

aiwilliams avatar aiwilliams commented on July 20, 2024

I am using @defunkt master branch. I am unable to create a Tempfile - No such file or directory - tmp. Is there any new knowledge about a fix for this?

from fakefs.

iainbeeston avatar iainbeeston commented on July 20, 2024

I'm also seeing this issue (using rspec with rails). Changing the require order doesn't seem to help

from fakefs.

iainbeeston avatar iainbeeston commented on July 20, 2024

It seems that Dir._check_for_valid_file('tmp') can't find the tmp dir in my rails install

from fakefs.

eventualbuddha avatar eventualbuddha commented on July 20, 2024

I've volunteered to update fakefs a little bit and triage the existing issues. Does anyone have a good reproducible test case for this? Please post a gist or something and I'll reopen.

from fakefs.

smtlaissezfaire avatar smtlaissezfaire commented on July 20, 2024

Awesome. Thanks for all of your hard work, Brian.

from fakefs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.