Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Verify test is blind to dynamically added Effect/Abilities #12191

Open
Susucre opened this issue Apr 28, 2024 · 0 comments
Open

Verify test is blind to dynamically added Effect/Abilities #12191

Susucre opened this issue Apr 28, 2024 · 0 comments
Labels
Developers Discussion Discussion about redesign or changes

Comments

@Susucre
Copy link
Contributor

Susucre commented Apr 28, 2024

I would like it if we could find a way to refactor effects so that the verify test deep (introduced for copy check, but it is doing a little more than that) looping through Card class can find oddities.

An option would be to have one instance of the added effect/ability as member of the class, and reuse/copy it on use. The instantitated one could be static in a lot of situations. Of course this would not help with every use case.

To give an example with DelayedTriggeredAbility:

public boolean apply(Game game, Ability source) {
DelayedTriggeredAbility delayedAbility = new JaceCunningCastawayDamageTriggeredAbility();
game.addDelayedTriggeredAbility(delayedAbility, source);
return true;
}

The JaceCunningCastawayDamageTriggeredAbility class is not covered by the Verify test suite.

@Susucre Susucre changed the title Verify test is blind to dynamically added Effect/DelayedTriggeredAbility Verify test is blind to dynamically added Effect/Abilities Apr 28, 2024
@Susucre Susucre added the Developers Discussion Discussion about redesign or changes label Apr 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Developers Discussion Discussion about redesign or changes
Projects
None yet
Development

No branches or pull requests

1 participant