Skip to content

Commit c14f265

Browse files
committed
lf-verify: Let it work at least somewhat.
1 parent b8c8f24 commit c14f265

File tree

1 file changed

+11
-17
lines changed

1 file changed

+11
-17
lines changed

lf_verify.pl

Lines changed: 11 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,11 @@
1212
# Un-buffer output
1313
$| = 1;
1414

15+
# use lib prepends to @INC, so put lower priority first
16+
# This is before run-time, so cannot condition this with normal 'if' logic.
17+
use lib '/home/lanforge/scripts';
18+
use lib "./";
19+
1520
use LANforge::Endpoint;
1621
use LANforge::Port;
1722
use LANforge::Utils;
@@ -26,14 +31,14 @@
2631

2732
# This sets up connections between 2 LANforge machines
2833
my $lf1 = 1;
29-
my $lf2 = 4;
34+
my $lf2 = 2;
3035

3136
# Port pairs. These are the ports that should be talking to each other.
3237
# Ie, the third column in lf1_ports talks to the third column in lf2_ports.
33-
my @lf1_ports = (4, 5, 2); # ,7);
34-
my @lf2_ports = (5, 6, 4); # ,5);
38+
my @lf1_ports = ("wlan0");
39+
my @lf2_ports = ("vap0000");
3540

36-
my $ports_are_connected = 1; # Connected to each other. If true, we can test some
41+
my $ports_are_connected = 0; # Connected to each other. If true, we can test some
3742
# ethernet driver settings more precisely.
3843

3944
my $manual_check = 0; # If this is true, then user input will be asked for each time
@@ -75,20 +80,9 @@
7580

7681
my $fail_msg = "";
7782

78-
# Open connection to the LANforge server.
79-
80-
my $t = new Net::Telnet(Prompt => '/default\@btbits\>\>/');
81-
82-
83-
$t->open(Host => $lfmgr_host,
84-
Port => $lfmgr_port,
85-
Timeout => 10);
86-
87-
$t->waitfor("/btbits\>\>/");
88-
8983
# Configure our utils.
90-
my $utils = new LANforge::Utils();
91-
$utils->telnet($t); # Set our telnet object.
84+
our $utils = new LANforge::Utils();
85+
$::utils->connect($lfmgr_host, $lfmgr_port);
9286
$utils->cli_send_silent(0); # Do show input to CLI
9387
$utils->cli_rcv_silent(0); # Repress output from CLI ??
9488

0 commit comments

Comments
 (0)