Code Monkey home page Code Monkey logo

Comments (8)

Fryguy avatar Fryguy commented on August 29, 2024

@ignatenkobrain How is this test being executed? I am running the tests with bundle exec rake, which is the expected way to run the tests, and the value of the output is

Usage: rake_test_loader usage string

Options:

(Note the rake_test_loader in my output vs -e in yours.

from optimist.

Fryguy avatar Fryguy commented on August 29, 2024

Even bundle exec ruby -Ilib:test test/optimist/parser_educate_test.rb passes on my machine with the following output

Usage: parser_educate_test usage string

Options:

from optimist.

ignatenkobrain avatar ignatenkobrain commented on August 29, 2024

basically it is executed in a ruby -Ilib:test test/optimist/parser_educate_test.rb way... But the main difference between build environment and your machine is that build environment does not have TTY, can that be related?

from optimist.

Fryguy avatar Fryguy commented on August 29, 2024

I'm not sure...it's more about what $0 is... the relevant portion of the code is:

https://github.com/ManageIQ/optimist/blob/master/lib/optimist.rb#L369-L370

which in your case is yielding -e. Do you know what $0 is in your case?

from optimist.

kbrock avatar kbrock commented on August 29, 2024

The only code that I feel could affect this is:

https://github.com/ManageIQ/optimist/blob/master/lib/optimist.rb#L391-L403

it should default to 80 wide for non tty

from optimist.

Fryguy avatar Fryguy commented on August 29, 2024

Right, but the error is because the program name is -e instead of something else. I mean the simple fix on our side it to just change the test on our side from \w* to [\w-]*, but I'd like to understand the deeper reason as to why a -e is there at all, and if there's a change that can be made on the packaging side, perhaps that's preferable than changing the this test?

from optimist.

nanobowers avatar nanobowers commented on August 29, 2024

IMO there's not enough information here to debug this, would recommend closing.

from optimist.

Fryguy avatar Fryguy commented on August 29, 2024

Reviewing this I recall that Red Hat does some interesting stuff when building rpms around gems, where they can run tests from within the rpm BUILDROOT, and it's like a special chroot'ed environment. I wonder if that's what's going on here? @ignatenkobrain I realize this issue is 4 years old, but do you have any more details?

from optimist.

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.