Tests: Use lint() where able instead of compile(). No functional change intended.

This commit is contained in:
Wilson Snyder 2024-01-20 10:24:54 -05:00
parent fef0502d50
commit 375a121377
49 changed files with 51 additions and 53 deletions

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(simulator => 1);
compile(
lint(
fails => 1,
expect_filename => $Self->{golden_filename},
);

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
expect_filename => $Self->{golden_filename},
verilator_flags2 => ['--assert'],
fails => 1,

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
expect_filename => $Self->{golden_filename},
verilator_flags2 => ['--assert'],
fails => 1,

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
expect_filename => $Self->{golden_filename},
verilator_flags2 => ['--assert'],
fails => 1,

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
expect_filename => $Self->{golden_filename},
verilator_flags2 => ['--assert'],
fails => 1,

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
expect_filename => $Self->{golden_filename},
verilator_flags2 => ['--assert'],
fails => 1,

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
expect_filename => $Self->{golden_filename},
verilator_flags2 => ['--assert --error-limit 1000'],
fails => 1,

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
expect_filename=>$Self->{golden_filename},
verilator_flags2=> ['--assert'],
fails => 1,

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(simulator => 1);
compile(
lint(
verilator_flags2 => ["--no-timing"],
fails => 1,
expect_filename => $Self->{golden_filename},

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(simulator => 1);
compile(
lint(
fails => 1,
expect_filename => $Self->{golden_filename},
);

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(simulator => 1);
compile(
lint(
fails => 1,
expect_filename => $Self->{golden_filename},
);

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(simulator => 1);
compile(
lint(
fails => 1,
expect_filename => $Self->{golden_filename},
);

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(linter => 1);
compile(
lint(
fails => 1,
expect_filename => $Self->{golden_filename},
);

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(linter => 1);
compile(
lint(
fails => 1,
expect_filename => $Self->{golden_filename},
);

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(linter => 1);
compile(
lint(
fails => 1,
expect_filename => $Self->{golden_filename},
);

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(linter => 1);
compile(
lint(
fails => 1,
expect_filename => $Self->{golden_filename},
);

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(simulator => 1);
compile(
lint(
verilator_flags2 => ["--no-timing"],
fails => 1,
expect_filename => $Self->{golden_filename},

View File

@ -14,7 +14,7 @@ scenarios(linter => 1);
lint(
fails => 1
);
);
ok(1);
1;

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
expect_filename=>$Self->{golden_filename},
verilator_flags2=> ['--assert'],
fails => 1,

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
expect_filename => $Self->{golden_filename},
verilator_flags2 => ['--assert --error-limit 1000'],
fails => 1,

View File

@ -10,10 +10,10 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
fails => 1,
expect_filename => $Self->{golden_filename},
);
);
ok(1);
1;

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(simulator => 1);
compile(
lint(
expect_filename => $Self->{golden_filename},
v_flags2 => ["--no-timing"],
fails => 1,

View File

@ -13,7 +13,7 @@ scenarios(linter => 1);
lint(
fails => 1,
expect_filename => $Self->{golden_filename},
);
);
ok(1);
1;

View File

@ -12,7 +12,7 @@ scenarios(vlt => 1); # no vltmt, as AstMemberSel is unhandled in V3InstrCount
top_filename("t_event_control_expr.v");
compile(
lint(
verilator_flags2 => ['-DUNSUP'],
fails => 1,
expect_filename => $Self->{golden_filename},

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
verilator_flags2 => ["--timing"],
fails => 1,
expect_filename => $Self->{golden_filename},

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
expect_filename => $Self->{golden_filename},
verilator_flags2 => ['--assert --timing'],
fails => 1,

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
verilator_flags2 => ["--instr-count-dpi -1"],
fails => 1,
expect => "%Error: --instr-count-dpi must be non-negative: -1"

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
verilator_flags2 => ['--exe --build --main --sc'],
verilator_make_cmake => 0,
verilator_make_gmake => 0,

View File

@ -11,7 +11,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
top_filename("t/t_flag_main.v");
compile(
lint(
verilator_make_cmake => 0,
verilator_make_gmake => 0,
verilator_flags2 => ["--binary -E --dpi-hdr-only --lint-only --xml-only -Wall"],

View File

@ -11,7 +11,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
top_filename("t/t_flag_main.v");
compile(
lint(
verilator_make_cmake => 0,
verilator_make_gmake => 0,
verilator_flags2 => ["--build -E -Wno-fatal --dpi-hdr-only --lint-only --xml-only"],

View File

@ -11,7 +11,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
top_filename("t/t_flag_main.v");
compile(
lint(
verilator_make_cmake => 0,
verilator_make_gmake => 0,
verilator_flags2 => ["-Wall --lint-only -Wno-fatal --dpi-hdr-only --xml-only"],

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
fails => 1,
expect_filename => $Self->{golden_filename},
);

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(linter => 1);
compile(
lint(
fails => 1,
expect_filename => $Self->{golden_filename},
);

View File

@ -8,9 +8,9 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
# Version 2.0.
# SPDX-License-Identifier: LGPL-3.0-only OR Artistic-2.0
scenarios(simulator => 1);
scenarios(linter => 1);
compile(
lint(
fails => 1,
expect_filename => $Self->{golden_filename},
);

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(linter => 1);
compile(
lint(
expect_filename => $Self->{golden_filename},
fails => 1,
);

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(linter => 1);
compile(
lint(
expect_filename => $Self->{golden_filename},
fails => 1,
);

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(linter => 1);
compile(
lint(
expect_filename => $Self->{golden_filename},
fails => 1,
);

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
verilator_flags2 => ["--lint-only -Wall -Wno-DECLFILENAME"],
fails => 1,
expect_filename => $Self->{golden_filename},

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
verilator_flags2 => ["--no-timing"],
fails => 1,
expect_filename => $Self->{golden_filename},

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(simulator => 1);
compile(
lint(
fails => 1,
expect_filename => $Self->{golden_filename},
);

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(simulator => 1);
compile(
lint(
verilator_flags2 => ["--no-timing"],
fails => 1,
expect_filename => $Self->{golden_filename},

View File

@ -12,7 +12,7 @@ scenarios(simulator => 1);
top_filename("t/t_timing_off.v");
compile(
lint(
verilator_flags2 => ["--no-timing"],
fails => 1,
expect_filename => $Self->{golden_filename},

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
# Bug1575 required trace to crash
verilator_flags2 => ["--trace --cc"],
fails => 1,

View File

@ -12,7 +12,7 @@ scenarios(simulator => 1);
top_filename("t/t_process.v");
compile(
lint(
expect_filename => $Self->{golden_filename},
v_flags2 => ["+define+T_PROCESS+std::process", "--no-timing"],
fails => 1,

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
expect_filename=>$Self->{golden_filename},
verilator_flags2=> ['--assert -Wno-UNSIGNED'],
fails => 1,

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
expect_filename => $Self->{golden_filename},
verilator_flags2 => ['--assert --error-limit 1000'],
fails => 1,

View File

@ -10,7 +10,7 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(vlt => 1);
compile(
lint(
fails => 1,
expect_filename => $Self->{golden_filename},
);

View File

@ -14,7 +14,7 @@ lint(
fails => 1,
verilator_flags2 => ['--stats'],
expect_filename => $Self->{golden_filename},
);
);
ok(1);
1;

View File

@ -10,13 +10,11 @@ if (!$::Driver) { use FindBin; exec("$FindBin::Bin/bootstrap.pl", @ARGV, $0); di
scenarios(simulator => 1);
compile(
lint(
verilator_flags2 => ['--structs-packed'],
fails => 1,
expect_filename => $Self->{golden_filename},
);
ok(1);
1;