public override bool Equals(object obj)
 {
     return(obj is SpotLight light &&
            location.Equals(light.location) &&
            intensity == light.intensity &&
            colors == light.colors);
 }
Example #2
0
        public void Tuple4NotEqualToAnotherType()
        {
            var t = new Tuple4(1, 1, 1, 1);

            Assert.False(t.Equals(42));
        }
Example #3
0
        public void Tuple4NotEqualToNull()
        {
            var t = new Tuple4(1, 1, 1, 1);

            Assert.False(t.Equals(null));
        }