From 8b867bbc441705f59b0795dceba7d3bc7f5b0678 Mon Sep 17 00:00:00 2001 From: Matthias Koefferlein Date: Sat, 18 Jul 2026 00:38:38 +0200 Subject: [PATCH] Fixing tests after layer names get loaded properly --- src/db/db/dbTestSupport.cc | 6 ++++-- src/db/db/dbTestSupport.h | 19 ++++++++++--------- .../net_tracer/unit_tests/dbTraceAllNets.cc | 2 +- 3 files changed, 15 insertions(+), 12 deletions(-) diff --git a/src/db/db/dbTestSupport.cc b/src/db/db/dbTestSupport.cc index f055a5980..3d2feb5be 100644 --- a/src/db/db/dbTestSupport.cc +++ b/src/db/db/dbTestSupport.cc @@ -163,8 +163,9 @@ void compare_layouts (tl::TestBase *_this, const db::Layout &layout, const std:: (n > 0 ? db::layout_diff::f_silent : db::layout_diff::f_verbose) | ((norm & AsPolygons) != 0 ? db::layout_diff::f_boxes_as_polygons + db::layout_diff::f_paths_as_polygons : 0) | ((norm & WithArrays) != 0 ? 0 : db::layout_diff::f_flatten_array_insts) - | ((norm & WithMeta) == 0 ? 0 : db::layout_diff::f_with_meta - | db::layout_diff::f_smart_cell_mapping) + | ((norm & WithMeta) == 0 ? 0 : db::layout_diff::f_with_meta) + | ((norm & WithoutLayerNames) == 0 ? 0 : db::layout_diff::f_no_layer_names) + | db::layout_diff::f_smart_cell_mapping /*| db::layout_diff::f_no_text_details | db::layout_diff::f_no_text_orientation*/ , tolerance, 100 /*max diff lines*/); @@ -176,6 +177,7 @@ void compare_layouts (tl::TestBase *_this, const db::Layout &layout, const std:: | ((norm & AsPolygons) != 0 ? db::layout_diff::f_boxes_as_polygons + db::layout_diff::f_paths_as_polygons : 0) | ((norm & WithArrays) != 0 ? 0 : db::layout_diff::f_flatten_array_insts) | ((norm & WithMeta) == 0 ? 0 : db::layout_diff::f_with_meta) + | ((norm & WithoutLayerNames) == 0 ? 0 : db::layout_diff::f_no_layer_names) /*| db::layout_diff::f_no_text_details | db::layout_diff::f_no_text_orientation*/ , tolerance, 100 /*max diff lines*/); diff --git a/src/db/db/dbTestSupport.h b/src/db/db/dbTestSupport.h index df013f8a1..1672cf86a 100644 --- a/src/db/db/dbTestSupport.h +++ b/src/db/db/dbTestSupport.h @@ -52,15 +52,16 @@ class Texts; */ enum NormalizationMode { - NoNormalization = 0, // no normalization - take the test subject as it is - WriteGDS2 = 1, // normalize subject by writing to GDS2 and reading back - WriteOAS = 2, // normalize subject by writing to OASIS and reading back - NormFileMask = 7, // bits the extract for file mode - NoContext = 8, // write tmp file without context - AsPolygons = 16, // paths and boxes are treated as polygons - WithArrays = 32, // do not flatten arrays - WithMeta = 64, // with meta info - WithoutCellNames = 128 // smart cell name mapping + NoNormalization = 0, // no normalization - take the test subject as it is + WriteGDS2 = 1, // normalize subject by writing to GDS2 and reading back + WriteOAS = 2, // normalize subject by writing to OASIS and reading back + NormFileMask = 7, // bits the extract for file mode + NoContext = 8, // write tmp file without context + AsPolygons = 16, // paths and boxes are treated as polygons + WithArrays = 32, // do not flatten arrays + WithMeta = 64, // with meta info + WithoutCellNames = 128, // smart cell name mapping + WithoutLayerNames = 256, // don't compare layer names }; /** diff --git a/src/plugins/tools/net_tracer/unit_tests/dbTraceAllNets.cc b/src/plugins/tools/net_tracer/unit_tests/dbTraceAllNets.cc index 7b7ad5259..0cc6d3e03 100644 --- a/src/plugins/tools/net_tracer/unit_tests/dbTraceAllNets.cc +++ b/src/plugins/tools/net_tracer/unit_tests/dbTraceAllNets.cc @@ -85,7 +85,7 @@ void run_test (tl::TestBase *_this, const std::string &file, const db::NetTracer fn += file_au; CHECKPOINT (); - db::compare_layouts (_this, layout_nets, fn, db::NormalizationMode (db::WriteOAS | db::AsPolygons)); + db::compare_layouts (_this, layout_nets, fn, db::NormalizationMode (db::WriteOAS | db::AsPolygons | db::WithoutLayerNames)); } TEST(1)