Skip to content

Instantly share code, notes, and snippets.

@soon
Last active August 29, 2015 14:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save soon/dfea3d1d48883b9c704a to your computer and use it in GitHub Desktop.
Save soon/dfea3d1d48883b9c704a to your computer and use it in GitHub Desktop.
using System.Linq;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using SampleAi;
namespace Tests
{
[TestClass]
public class MapTests
{
#region Tests
[TestMethod]
public void TestKill()
{
Map.Init(20, 20);
Map.Wound(new Point(1, 4));
Map.Wound(new Point(1, 5));
Map.Wound(new Point(1, 6));
Map.Kill(new Point(1, 7));
Assert.AreEqual(0, Map.GetAllShipPoints().Count());
}
[TestMethod]
public void TestKill_DoesNotWork()
{
Map.Init(20, 20);
Map.Wound(new Point(1, 4));
Map.Wound(new Point(1, 5));
Map.Wound(new Point(1, 6));
Map.Kill_DoesNotWork(new Point(1, 7));
Assert.AreEqual(0, Map.GetAllShipPoints().Count());
}
#endregion // Tests
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment