public async Task Repeat_BadlandsWorksOnBothTargets() { var fix = new ConfigurableTestFixture(); var space1 = fix.Board[3]; var space2 = fix.Board[8]; // Given: 2 sun, 3 fire, 3 earth fix.InitElements("2 sun,3 fire,3 earth"); // And: target land #1 has 1 presence, 3 explorers and 1 town fix.InitPresence(space1, 1); fix.InitTokens(space1, "3E@1,1T@2"); // And: target land #2 has the same (1 presence, 3 explorers and 1 town) fix.InitPresence(space2, 1); fix.InitTokens(space2, "3E@1,1T@2"); // When: play card var task = PowerCard.For <ForestsOfLivingObsidian>().ActivateAsync(fix.SelfCtx); // And: targeting space 1 fix.Choose(space1); fix.Choose("T@1"); // Damage (1 remaining) // And: targeting space 2 fix.Choose(space2); fix.Choose("T@1"); // Damage (1 remaining) task.IsCompletedSuccessfully.ShouldBeTrue(); }
public async Task Repeat_BadlandsWorksOnSameTargetTwice() { var fix = new ConfigurableTestFixture(); var space1 = fix.Board[3]; // Given: 2 sun, 3 fire, 3 earth fix.InitElements("2 sun,3 fire,3 earth"); // And: target land has 1 presence, 2 Cities fix.Spirit.Presence.Adjust(space1, 1); fix.InitTokens(space1, "3C@3"); // When: play card var task = PowerCard.For <ForestsOfLivingObsidian>().ActivateAsync(fix.SelfCtx); // And: targeting space 1 fix.Choose(space1); fix.Choose("C@2"); // 3C@2 - Damage 1 of them (1 of 1) fix.GameState.Tokens[space1].Summary.ShouldBe("1C@1,2C@2,1M"); // And: targeting space 1 a 2nd time fix.Choose(space1); // Should Kill the 1C@1, and reduce the 2C@2 to 2C@1 fix.Choose("C@1"); // Kill 1st City fix.Choose("C@1"); // Kill 2nd City fix.GameState.Tokens[space1].Summary.ShouldBe("2M"); task.IsCompletedSuccessfully.ShouldBeTrue(); }
public void ReturningKeeperPresence_PushesDahan() { var fix = new ConfigurableTestFixture { Spirit = new Keeper() }; var space = fix.Board[5]; var dahanDestination = space.Adjacent.First(); // Given: Keeper has a destroyed presence fix.Spirit.Presence.Destroyed = 1; // And: a presence on target space. fix.Spirit.Presence.Adjust(space, 1); // And: Dahan on space fix.InitTokens(space, "1D@2"); // When: play the card var task = PowerCard.For <SkiesHeraldTheSeasonOfReturn>().ActivateAsync(fix.SelfCtx); // target space fix.Choose(space); // Then: Should Push Dahan (per keeper's Sacred Site) fix.Choose("D@2"); fix.Choose(dahanDestination); // And: May Gather up to 2 dahan (per the card) fix.Choose("D@2 on " + dahanDestination.Text); // "Gather up to 2 Dahan" // And: May push 1 blight // no blight to push task.IsCompletedSuccessfully.ShouldBeTrue(); }
public void Level2_2DamagePush3TownOrExplorers() // 2-Sun, 3-Water { var fixture = new ConfigurableTestFixture(); var space = fixture.Board[5]; var tokens = fixture.GameState.Tokens[space]; var destination = space.Adjacent.Last(); // Given: spirit has a sacred site adjacent to the target space (range-1) fixture.Spirit.Presence.Adjust(space.Adjacent.First(), 2); // And: Spirit has enough elements to trigger Level-2 of Massive Flooding fixture.InitElements("3 water,2 sun"); // And: target has 1 city, 4 towns, 5 explorers - !!! collapse this to 1 line fixture.InitTokens(space, "1C@3,4T@2,5E@1"); // When: activate innate _ = InnatePower.For <MassiveFlooding>().ActivateAsync(fixture.SelfCtx); fixture.Choose(space); // target space fixture.Choose(Tokens.Town); // 1st damage fixture.Choose(Tokens.Town1); // 2nd damage fixture.ChoosePush(Tokens.Town, destination); // push 1 fixture.ChoosePush(Tokens.Town, destination); // push 2 fixture.ChoosePush(Tokens.Explorer, destination); // push 3 // Then: target has remaining invaders tokens.Summary.ShouldBe("1C@3,4E@1,1T@2"); // And: destination had pushed invaders fixture.GameState.Tokens[destination].Summary.ShouldBe("1E@1,2T@2"); }
public void Level1_Pushes1TownOrExplorer() // 1-Sun, 2-Water { var fixture = new ConfigurableTestFixture(); var space = fixture.Board[5]; var tokens = fixture.GameState.Tokens[space]; var destination = space.Adjacent.Last(); // Given: spirit has a sacred site adjacent to the target space (range-1) fixture.Spirit.Presence.Adjust(space.Adjacent.First(), 2); // And: Spirit has enough elements to trigger Level-1 of Massive Flooding fixture.InitElements("1 sun,2 water"); // And: target has 1 city, 4 towns, 5 explorers fixture.InitTokens(space, "1C@3,5E@1,4T@2"); // When: activate innate _ = InnatePower.For <MassiveFlooding>().ActivateAsync(fixture.SelfCtx); fixture.Choose(space); // target space fixture.ChoosePush(Tokens.Town, destination); // push 1 // Then: target has remaining invaders tokens.Summary.ShouldBe("1C@3,5E@1,3T@2"); // And: destination had pushed invaders fixture.GameState.Tokens[destination].Summary.ShouldBe("1T@2"); }
public void Level3_2DamageToEachInvader() // 3 sun, 4 water, 1 earth { var fixture = new ConfigurableTestFixture(); var space = fixture.Board[5]; var tokens = fixture.GameState.Tokens[space]; // Given: spirit has a sacred site adjacent to the target space (range-1) fixture.Spirit.Presence.Adjust(space.Adjacent.First(), 2); // And: Spirit has enough elements to trigger Level-3 of Massive Flooding fixture.InitElements("3 sun,4 water,1 earth"); // And: target has 1 city, 4 towns, 5 explorers - !!! collapse this to 1 line fixture.InitTokens(space, "1C@3,4T@2,5E@1"); // When: activate innate _ = InnatePower.For <MassiveFlooding>().ActivateAsync(fixture.SelfCtx); fixture.Choose(space); // target space // Then: target has remaining invaders tokens.Summary.ShouldBe("1C@1"); }