public void ExpectingSword_OnNinjaWithNullWeapons_ShouldFail() { // act var result = new WeaponedNinja(null).Evaluate(n => n.Member(x => x.Weapons).Contains("Sword")); // assert result.ExAssert(r => r.Member(x => x.succeeded).IsFalse() .Member(x => x.actual).IsEqualTo("WeaponedNinja: (X)Weapons = null") .Member(x => x.expectation).Contains("contains ['Sword']")); }
public void ExpectingNoSwordAndShuriken_OnNullWeaponNinja_ShouldSucceed() { // act var result = new WeaponedNinja(null).Evaluate(n => n.Member(x => x.Weapons).DoesntContain("Sword", "Shuriken")); // assert result.ExAssert(r => r.Member(x => x.succeeded).IsTrue() .Member(x => x.actual).IsEqualTo("WeaponedNinja: ( )Weapons = null") .Member(x => x.expectation).Contains("doesn't contain ['Sword', 'Shuriken']")); }