public void Object_Equals_Scope_Different()
        {
            // arrange
            ExtendedTypeReference x = TypeReference.Create(
                _typeInspector.GetType(typeof(string)),
                TypeContext.None,
                scope: "a");

            var y = TypeReference.Create(
                _typeInspector.GetType(typeof(string)),
                TypeContext.Output,
                scope: "a");

            var z = TypeReference.Create(
                _typeInspector.GetType(typeof(string)),
                TypeContext.Input);

            // act
            var xy = x.Equals((object)y);
            var xz = x.Equals((object)z);
            var yz = y.Equals((object)z);

            // assert
            Assert.True(xy);
            Assert.False(xz);
            Assert.False(yz);
        }
        public void ITypeReference_Equals_Context_None_Does_Not_Matter()
        {
            // arrange
            ExtendedTypeReference x = TypeReference.Create(
                _typeInspector.GetType(typeof(string)),
                TypeContext.None);

            var y = TypeReference.Create(
                _typeInspector.GetType(typeof(string)),
                TypeContext.Output);

            var z = TypeReference.Create(
                _typeInspector.GetType(typeof(string)),
                TypeContext.Input);

            // act
            var xy = x.Equals((ITypeReference)y);
            var xz = x.Equals((ITypeReference)z);
            var yz = y.Equals((ITypeReference)z);

            // assert
            Assert.True(xy);
            Assert.True(xz);
            Assert.False(yz);
        }
        public void ClrTypeReference_Equals_To_Same()
        {
            // arrange
            ExtendedTypeReference x = TypeReference.Create(
                _typeInspector.GetType(typeof(string)));

            // act
            var xx = x.Equals((ExtendedTypeReference)x);

            // assert
            Assert.True(xx);
        }
        public void ClrTypeReference_Equals_To_Null()
        {
            // arrange
            ExtendedTypeReference x = TypeReference.Create(
                _typeInspector.GetType(typeof(string)));

            // act
            var result = x.Equals((ExtendedTypeReference)null);

            // assert
            Assert.False(result);
        }
        public void Object_Equals_To_Object()
        {
            // arrange
            ExtendedTypeReference x = TypeReference.Create(
                _typeInspector.GetType(typeof(string)));

            // act
            var xx = x.Equals(new object());

            // assert
            Assert.False(xx);
        }
        public void ITypeReference_Equals_To_SyntaxTypeRef()
        {
            // arrange
            ExtendedTypeReference x = TypeReference.Create(
                _typeInspector.GetType(typeof(string)));

            // act
            var xx = x.Equals(TypeReference.Create(new NameType("foo")));

            // assert
            Assert.False(xx);
        }