Not Passing On Command Line Arguments

D

Dylan

Hey there! I have a question about passing command line arguments. I
have a list of arguments I'd like to use alongside a couple built in
to Test::Case. However, I keep getting an "invalid argument" error
every time. Is there a way to handle my command line arguments and
remove them from the array that gets passed to Test::Case or change
how Test::Case handles arguments? I've tried writing my own
OptionsParser instance in my code, as well as editing autorunner.rb
(where OptionsParser is used in Test::Case) and adding my arguments
there ( o.on('-c', '--cleanup', "Clean up stuff"){puts
"CLEANUPPP!";exit} ), but even if I try to change the arguments that
are already there (Changing the help text, for example), nothing seems
to show up any different. Thanks!

-Dylan
 
D

Dylan

Hey there! I have a question about passing command line arguments. I
have a list of arguments I'd like to use alongside a couple built in
to Test::Case. However, I keep getting an "invalid argument" error
every time. Is there a way to handle my command line arguments and
remove them from the array that gets passed to Test::Case or change
how Test::Case handles arguments? I've tried writing my own
OptionsParser instance in my code, as well as editing autorunner.rb
(where OptionsParser is used in Test::Case) and adding my arguments
there ( o.on('-c', '--cleanup', "Clean up stuff"){puts
"CLEANUPPP!";exit} ), but even if I try to change the arguments that
are already there (Changing the help text, for example), nothing seems
to show up any different. Thanks!

-Dylan

Also, for some reason some arguments I add (by simply adding if
(ARGV.include? "-cleanup") ) work fine, but gives an warning:
Deprecated option (--console). Thanks!

-Dylan
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top