Move all battle state from IPokemon to an ephemeral IBattlePokemon wrapper
This commit is contained in:
@@ -16,15 +16,15 @@ public class FacadeTests
|
||||
{
|
||||
/// <summary>
|
||||
/// Creates a fully mocked test setup where the user has the given (or no) non-volatile status in its
|
||||
/// <see cref="IPokemon.StatusScript"/>, and is using a move of the given category.
|
||||
/// <see cref="IBattlePokemon.StatusScript"/>, and is using a move of the given category.
|
||||
/// </summary>
|
||||
private static (Facade facade, IExecutingMove move, IPokemon target) CreateTestSetup(Script? status,
|
||||
private static (Facade facade, IExecutingMove move, IBattlePokemon target) CreateTestSetup(Script? status,
|
||||
MoveCategory category = MoveCategory.Physical)
|
||||
{
|
||||
var facade = new Facade();
|
||||
var move = Substitute.For<IExecutingMove>();
|
||||
var target = Substitute.For<IPokemon>();
|
||||
var user = Substitute.For<IPokemon>();
|
||||
var target = Substitute.For<IBattlePokemon>();
|
||||
var user = Substitute.For<IBattlePokemon>();
|
||||
user.StatusScript.Returns(status == null ? new ScriptContainer() : new ScriptContainer(status));
|
||||
move.User.Returns(user);
|
||||
var useMove = Substitute.For<IMoveData>();
|
||||
|
||||
Reference in New Issue
Block a user