public async Task ShouldEnqueueHelloAndSync()
        {
            var protocol = new BoltProtocolV4_4(new Dictionary <string, string> {
                { "ContextKey", "ContextValue" }
            });

            await EnqueAndSync(protocol);
        }
        public async Task GetRoutingTableShouldThrowOnNullConnectionObject()
        {
            var protocol = new BoltProtocolV4_4(new Dictionary <string, string> {
                { "ContextKey", "ContextValue" }
            });

            var ex = await Xunit.Record.ExceptionAsync(async() => await protocol.GetRoutingTable(null, "adb", null, null));

            ex.Should().BeOfType <ProtocolException>().Which
            .Message.Should()
            .Contain("Attempting to get a routing table on a null connection");
        }
        public async Task ShouldNotThrowOnImpersonatedUserAsync(string impUser)
        {
            var protocol = new BoltProtocolV4_4(new Dictionary <string, string> {
                { "ContextKey", "ContextValue" }
            });
            var mockConn = NewConnectionWithMode(AccessMode.Read);

            var exception = await Xunit.Record.ExceptionAsync(async() => await protocol.BeginTransactionAsync(mockConn.Object,
                                                                                                              string.Empty,
                                                                                                              Bookmark.From("123"),
                                                                                                              TransactionConfig.Default,
                                                                                                              impUser));

            Assert.Null(exception);
        }
        public async void ShouldEnqueueHelloAndSyncNullContext()
        {
            var protocol = new BoltProtocolV4_4(null);

            await EnqueAndSync(protocol);
        }
        public async Task ShouldEnqueueHelloAndSyncEmptyContext()
        {
            var protocol = new BoltProtocolV4_4(new Dictionary <string, string>());

            await EnqueAndSync(protocol);
        }