示例#1
0
            public void Returns_true_for_equal_objects()
            {
                Func <TransactionHandler> transactionHandlerFactory = () => new Mock <TransactionHandler>().Object;
                var resolver1 = new TransactionHandlerResolver(transactionHandlerFactory, "p", "s");
                var resolver2 = new TransactionHandlerResolver(transactionHandlerFactory, "p", "s");

                Assert.True(resolver1.Equals(resolver2));
            }
示例#2
0
            public void Returns_false_for_different_factories()
            {
                var resolver1 = new TransactionHandlerResolver(() => new Mock <TransactionHandler>().Object, "p", "s");
                var resolver2 = new TransactionHandlerResolver(() => new Mock <TransactionHandler>().Object, "p", "s");

                Assert.False(resolver1.Equals(resolver2));
                Assert.False(resolver2.Equals(resolver1));
            }
示例#3
0
            public void Returns_false_for_different_servers()
            {
                Func <TransactionHandler> transactionHandlerFactory = () => new Mock <TransactionHandler>().Object;
                var resolver1 = new TransactionHandlerResolver(transactionHandlerFactory, "p", "s");
                var resolver2 = new TransactionHandlerResolver(transactionHandlerFactory, "p", null);

                Assert.False(resolver1.Equals(resolver2));
                Assert.False(resolver2.Equals(resolver1));
            }
示例#4
0
            public void Returns_false_for_different_type()
            {
                var resolver = new TransactionHandlerResolver(() => new Mock <TransactionHandler>().Object, "p", "s");

                Assert.False(resolver.Equals(new object()));
            }
            public void Returns_false_for_different_servers()
            {
                Func<TransactionHandler> transactionHandlerFactory = () => new Mock<TransactionHandler>().Object;
                var resolver1 = new TransactionHandlerResolver(transactionHandlerFactory, "p", "s");
                var resolver2 = new TransactionHandlerResolver(transactionHandlerFactory, "p", null);

                Assert.False(resolver1.Equals(resolver2));
                Assert.False(resolver2.Equals(resolver1));
            }
            public void Returns_false_for_different_factories()
            {
                var resolver1 = new TransactionHandlerResolver(() => new Mock<TransactionHandler>().Object, "p", "s");
                var resolver2 = new TransactionHandlerResolver(() => new Mock<TransactionHandler>().Object, "p", "s");

                Assert.False(resolver1.Equals(resolver2));
                Assert.False(resolver2.Equals(resolver1));
            }
            public void Returns_false_for_different_type()
            {
                var resolver = new TransactionHandlerResolver(() => new Mock<TransactionHandler>().Object, "p", "s");

                Assert.False(resolver.Equals(new object()));
            }
            public void Returns_true_for_equal_objects()
            {
                Func<TransactionHandler> transactionHandlerFactory = () => new Mock<TransactionHandler>().Object;
                var resolver1 = new TransactionHandlerResolver(transactionHandlerFactory, "p", "s");
                var resolver2 = new TransactionHandlerResolver(transactionHandlerFactory, "p", "s");

                Assert.True(resolver1.Equals(resolver2));
            }