public void IfIDontPassAnObjectToMethodOneItFails()
 {
     try
     {
         classToTest = new ClassOne(new object());
         classToTest.MethodOne(null);
         Assert.Fail();
     }
     catch (NotObjectPassedException)
     {
         Assert.IsTrue(true);
     }
 }
 public void MethodOneDoesSomeThingAndReturnsSomething()
 {
     classToTest = new ClassOne(new object());
     var result = classToTest.MethodOne(new List());
     Assert.IsTrue(result);
 }
 public void MethodOneDoesSomethingAndReturnsOtherThing()
 {
     classToTest = new ClassOne(new object());
     var result = classToTest.MethodOne(string.Empty);
     Assert.IsFalse(result);
 }
Esempio n. 4
0
 public void MethodOneDoesSomeThingAndReturnsSomething()
 {
     classToTest = new ClassOne(new object());
     var result = classToTest.MethodOne(new List());
     result.Should().Be(true);
 }
Esempio n. 5
0
 public void MethodOneDoesSomethingAndReturnsOtherThing()
 {
     classToTest = new ClassOne(new object());
     var result = classToTest.MethodOne(string.Empty);
     result.Should().Be(false);
 }
Esempio n. 6
0
 public void IfIDontPassAnObjectToMethodOneItFails()
 {
     classToTest = new ClassOne(new object());
     Action act = () => classToTest.MethodOne(null);
     act.ShouldThrow<NotObjectPassedException>();
 }