[Refactor] Give graphics zones a card item cache and own card placement

This commit is contained in:
Lukas Brübach 2026-10-06 17:47:23 +02:00 • committed by GitHub
parent 8347258075
commit cea80b0898
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
18 changed files with 111 additions and 74 deletions

View file

@ -16,7 +16,6 @@ struct MockCard
bool cardRefWasCalled = false;
bool resetStateCalled = false;
bool resetStateKeepAnnotations = false;
bool visibleSet = false;
void setId(int id)
{
@ -35,11 +34,6 @@ struct MockCard
resetStateCalled = true;
resetStateKeepAnnotations = keepAnnotations;
}
void setVisible(bool visible)
{
visibleSet = visible;
}
};
class MockCardList
@ -109,7 +103,6 @@ TEST_F(AddCardAlgorithmTest, ContentsKnownPreservesIdentity)
EXPECT_FALSE(card.idWasCalled);
EXPECT_FALSE(card.cardRefWasCalled);
EXPECT_TRUE(card.visibleSet);
}
TEST_F(AddCardAlgorithmTest, ContentsUnknownClearsIdentity)