public Equals ( object obj ) : bool | ||
obj | object | The |
return | bool |
public void EqualsSameObjectTest() { var token = new BooleanToken(true); Assert.True(token.Equals(token)); Assert.Equal(token, token); }
public void EqualsDiffTypeTest() { var token = new BooleanToken(true); Assert.False(token.Equals(1)); Assert.NotEqual((object)1, token); }
public void EqualsNullTest() { var token = new BooleanToken(true); Assert.False(token.Equals(null)); Assert.NotEqual(null, token); }
public void EqualsDiffBoolTest() { var token1 = new BooleanToken(true); var token2 = new BooleanToken(false); Assert.False(token1.Equals(token2)); Assert.NotEqual(token1, token2); }