Skip to content

Instantly share code, notes, and snippets.

@mikasjp
Created March 16, 2017 18:11
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 mikasjp/178b1d7634add2967362abce74b5383c to your computer and use it in GitHub Desktop.
Save mikasjp/178b1d7634add2967362abce74b5383c to your computer and use it in GitHub Desktop.
namespace InertialNavigationSystem_Test
{
[TestFixture]
public class IntegratorTest
{
[Test]
public void IntegrateSamples()
{
List<Sample> samples = new List<Sample>()
{
new Sample(0,1),
new Sample(1,1),
new Sample(2,1)
};
Integrator integrator = new Integrator(samples);
Assert.AreEqual(2, integrator.Value);
}
[Test]
public void AddSampleAndIntegrate()
{
Integrator integrator = new Integrator();
integrator.AddSample(new Sample(0,1));
//Assert.AreEqual(0, integrator.Value);
integrator.AddSample(new Sample(1, 1));
Assert.AreEqual(1, integrator.Value);
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment