1N/A#!./perl -w
1N/A
1N/ABEGIN {
1N/A if ($ENV{PERL_CORE}) {
1N/A @INC = '../lib';
1N/A chdir 't';
1N/A }
1N/A}
1N/A
1N/Arequire "newgetopt.pl";
1N/A
1N/Aprint "1..9\n";
1N/A
1N/A@ARGV = qw(-Foo -baR --foo bar);
1N/A$newgetopt::ignorecase = 0;
1N/A$newgetopt::ignorecase = 0;
1N/Aundef $opt_baR;
1N/Aundef $opt_bar;
1N/Aprint "ok 1\n" if NGetOpt ("foo", "Foo=s");
1N/Aprint ((defined $opt_foo) ? "" : "not ", "ok 2\n");
1N/Aprint (($opt_foo == 1) ? "" : "not ", "ok 3\n");
1N/Aprint ((defined $opt_Foo) ? "" : "not ", "ok 4\n");
1N/Aprint (($opt_Foo eq "-baR") ? "" : "not ", "ok 5\n");
1N/Aprint ((@ARGV == 1) ? "" : "not ", "ok 6\n");
1N/Aprint (($ARGV[0] eq "bar") ? "" : "not ", "ok 7\n");
1N/Aprint (!(defined $opt_baR) ? "" : "not ", "ok 8\n");
1N/Aprint (!(defined $opt_bar) ? "" : "not ", "ok 9\n");