예제 #1
0
        public async Task Authentication_ConnectConcurrently2ConnectorsToTestMasterShouldSucceed()
        {
            //Arrange
            bool signInResult1 = await _connector.SignIn(Identity, true);

            var secondConnector = new AgentConnector()
            {
                Host = _host
            };
            var  secondIdentity = CreateUserIdentity();
            bool signInResult2  = await secondConnector.SignIn(secondIdentity, true);

            //Act
            var result1 = await _connector.Connect();

            var result2 = await secondConnector.Connect();

            //Assert
            Assert.True(signInResult1, "Sign-in first connector failed.");
            Assert.True(signInResult2, "Sign-in second connector failed.");
            Assert.True(result1, "Connect first connector failed.");
            Assert.True(result2, "Connect second connector failed.");

            await _connector.SignOut();

            await secondConnector.SignOut();
        }
예제 #2
0
 public async Task Disconnect()
 {
     await _connector.SignOut();
 }