mirror of
https://github.com/KLayout/klayout.git
synced 2026-09-03 06:43:29 +02:00
WIP: added one more level of abstraction to layout-to-netlist extraction (db::LayoutToNetlist) for easier use.
This commit is contained in:
@@ -428,6 +428,12 @@ TEST(1a)
|
||||
x = collect(i5, g);
|
||||
EXPECT_EQ (x, "[$2](0,100;1000,1200)/[$3](100,0;1100,1100)/[$4](1200,0;2200,1100)/[$4](-1200,0;-100,1000)");
|
||||
|
||||
i5.set_layer (1);
|
||||
x = collect_with_copy(i5, g);
|
||||
EXPECT_EQ (x, "[$3](101,1;1101,1101)");
|
||||
x = collect(i5, g);
|
||||
EXPECT_EQ (x, "[$3](101,1;1101,1101)");
|
||||
|
||||
std::set<unsigned int> ll;
|
||||
|
||||
db::RecursiveShapeIterator i5a (g, c0, ll, db::Box::world ());
|
||||
@@ -454,6 +460,14 @@ TEST(1a)
|
||||
EXPECT_EQ (x, "[$2](0,100;1000,1200)*0/[$3](100,0;1100,1100)*0/[$3](101,1;1101,1101)*1/[$4](1200,0;2200,1100)*0/[$4](-1200,0;-100,1000)*0");
|
||||
x = collect(i5cc, g, true);
|
||||
EXPECT_EQ (x, "[$2](0,100;1000,1200)*0/[$3](100,0;1100,1100)*0/[$3](101,1;1101,1101)*1/[$4](1200,0;2200,1100)*0/[$4](-1200,0;-100,1000)*0");
|
||||
|
||||
std::vector<unsigned int> ll_new;
|
||||
ll_new.push_back (0);
|
||||
i5c.set_layers (ll_new);
|
||||
x = collect_with_copy(i5c, g, true);
|
||||
EXPECT_EQ (x, "[$2](0,100;1000,1200)*0/[$3](100,0;1100,1100)*0/[$4](1200,0;2200,1100)*0/[$4](-1200,0;-100,1000)*0");
|
||||
x = collect(i5c, g, true);
|
||||
EXPECT_EQ (x, "[$2](0,100;1000,1200)*0/[$3](100,0;1100,1100)*0/[$4](1200,0;2200,1100)*0/[$4](-1200,0;-100,1000)*0");
|
||||
}
|
||||
|
||||
TEST(1b)
|
||||
|
||||
Reference in New Issue
Block a user