Skip to content

Commit

Permalink
removed cache from tests
Browse files Browse the repository at this point in the history
  • Loading branch information
SJulianS committed May 15, 2024
1 parent a0f5e2f commit 2c75e8d
Showing 1 changed file with 0 additions and 18 deletions.
18 changes: 0 additions & 18 deletions tests/netlist/decorators.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -672,15 +672,6 @@ namespace hal {
EXPECT_TRUE(res.is_ok());
EXPECT_EQ(res.get(), std::set<Gate*>({dff4, dff5, dff6}));
}
{
std::unordered_map<const Net*, std::set<Gate*>> cache;
const auto res1 = trav_dec.get_next_matching_gates(dff2, true, [](const Gate* g) { return g->get_type()->has_property(GateTypeProperty::ff); }, false, nullptr, nullptr, &cache);
EXPECT_TRUE(res1.is_ok());
EXPECT_EQ(res1.get(), std::set<Gate*>({dff5, dff6, dff7, dff3}));
const auto res2 = trav_dec.get_next_matching_gates(dff3, true, [](const Gate* g) { return g->get_type()->has_property(GateTypeProperty::ff); }, false, nullptr, nullptr, &cache);
EXPECT_TRUE(res2.is_ok());
EXPECT_EQ(res2.get(), std::set<Gate*>({dff6, dff7, dff3}));
}

// predecessors
{
Expand All @@ -693,15 +684,6 @@ namespace hal {
EXPECT_TRUE(res.is_ok());
EXPECT_EQ(res.get(), std::set<Gate*>({dff0, dff1, dff2}));
}
{
std::unordered_map<const Net*, std::set<Gate*>> cache;
const auto res1 = trav_dec.get_next_matching_gates(dff6, false, [](const Gate* g) { return g->get_type()->has_property(GateTypeProperty::ff); }, false, nullptr, nullptr, &cache);
EXPECT_TRUE(res1.is_ok());
EXPECT_EQ(res1.get(), std::set<Gate*>({dff1, dff2, dff3, sff0, sff1}));
const auto res2 = trav_dec.get_next_matching_gates(dff7, false, [](const Gate* g) { return g->get_type()->has_property(GateTypeProperty::ff); }, false, nullptr, nullptr, &cache);
EXPECT_TRUE(res2.is_ok());
EXPECT_EQ(res2.get(), std::set<Gate*>({dff2, dff3, sff0, sff1}));
}
}
{
// test NetlistModificationDecorator::get_next_matching_gates_until
Expand Down

0 comments on commit 2c75e8d

Please sign in to comment.