From 1248af1e022e38211febf510976a0799cb767524 Mon Sep 17 00:00:00 2001 From: Krystine Sherwin <93062060+KrystalDelusion@users.noreply.github.com> Date: Mon, 6 Oct 2025 14:22:18 +1300 Subject: [PATCH] Tests: Prefer single quotes for regex Replaces double quotes on problematic regex strings (mostly ones that have escape sequences that are easier to preserve in single quotes). Necessitates also changing single quotes to `.`, i.e match any. For some (mostly ones that only have a single escaped character, or were using `\.` to match a literal fullstop) keep the double quotes and fix the regex instead. --- examples/smtbmc/glift/mux2.ys | 10 +++++----- tests/arch/xilinx/abc9_dff.ys | 12 ++++++------ tests/scripts/space_in_name.ys | 7 ++++--- tests/select/boxes_import.ys | 4 ++-- tests/select/unset.ys | 2 +- tests/svtypes/typedef_initial_and_assign.ys | 16 ++++++++-------- tests/various/printattr.ys | 2 +- tests/various/src.ys | 4 ++-- tests/various/sta.ys | 6 +++--- tests/various/stat.ys | 4 ++-- tests/various/stat_high_level.ys | 4 ++-- tests/various/stat_high_level2.ys | 4 ++-- tests/various/sv_defines_mismatch.ys | 2 +- tests/various/sv_defines_too_few.ys | 2 +- tests/verilog/always_comb_latch_1.ys | 2 +- tests/verilog/always_comb_latch_2.ys | 2 +- tests/verilog/always_comb_latch_3.ys | 2 +- tests/verilog/always_comb_latch_4.ys | 2 +- tests/verilog/block_end_label_only.ys | 2 +- tests/verilog/block_end_label_wrong.ys | 2 +- tests/verilog/block_labels.ys | 2 +- tests/verilog/bug2493.ys | 2 +- tests/verilog/conflict_assert.ys | 2 +- tests/verilog/conflict_cell_memory.ys | 2 +- tests/verilog/conflict_interface_port.ys | 2 +- tests/verilog/conflict_memory_wire.ys | 2 +- tests/verilog/conflict_pwire.ys | 2 +- tests/verilog/conflict_wire_memory.ys | 2 +- tests/verilog/gen_block_end_label_only.ys | 2 +- tests/verilog/gen_block_end_label_wrong.ys | 2 +- tests/verilog/genblk_port_decl.ys | 2 +- tests/verilog/hidden_decl.ys | 2 +- tests/verilog/macro_unapplied.ys | 2 +- tests/verilog/macro_unapplied_newline.ys | 2 +- tests/verilog/module_end_label.ys | 2 +- tests/verilog/package_end_label.ys | 2 +- tests/verilog/param_no_default_unbound_1.ys | 2 +- tests/verilog/param_no_default_unbound_2.ys | 2 +- tests/verilog/param_no_default_unbound_3.ys | 2 +- tests/verilog/param_no_default_unbound_4.ys | 2 +- tests/verilog/param_no_default_unbound_5.ys | 2 +- tests/verilog/string-literals.ys | 4 ++-- tests/verilog/wire_and_var.ys | 10 +++++----- 43 files changed, 74 insertions(+), 73 deletions(-) diff --git a/examples/smtbmc/glift/mux2.ys b/examples/smtbmc/glift/mux2.ys index a8e99912b..e844e96e3 100644 --- a/examples/smtbmc/glift/mux2.ys +++ b/examples/smtbmc/glift/mux2.ys @@ -1,9 +1,9 @@ logger -expect log "SAT proof finished - no model found: SUCCESS!" 1 -logger -expect log "Number of cells:.*[\t ]12" 1 -logger -expect log "Number of cells:.*[\t ]20" 1 -logger -expect log "Problem is satisfiable with \\gate.__glift_weight = 11." 1 -logger -expect log "Problem is NOT satisfiable with \\gate.__glift_weight <= 10." 1 -logger -expect log "Wire \\gate.__glift_weight is minimized at 11." 1 +logger -expect log 'Number of cells:.*[\t ]12' 1 +logger -expect log 'Number of cells:.*[\t ]20' 1 +logger -expect log 'Problem is satisfiable with \\gate.__glift_weight = 11.' 1 +logger -expect log 'Problem is NOT satisfiable with \\gate.__glift_weight <= 10.' 1 +logger -expect log 'Wire \\gate.__glift_weight is minimized at 11.' 1 logger -expect log "Specializing .* from file with .* = 1." 2 logger -expect log "Specializing .* from file with .* = 0." 4 read_verilog <