예제 #1
0
        public void InvalidCredentialThrows()
        {
            var sut = new HttpTesonetApi();
            Func <Task <IServers> > servers = () => sut.Login(new Credentials("test", "test"), default);

            servers.Should().Throw <AppException>().WithMessage("Invalid user name or password");
        }
예제 #2
0
        public async Task ValidCredentialsReturnsServers()
        {
            var sut     = new HttpTesonetApi();
            var servers = await sut.Login(new Credentials("tesonet", "partyanimal"), default);

            servers.Should().NotBeNull();
        }