Exemplo n.º 1
0
        public void Ctor_SetsCorrectProviderName()
        {
            // Arrange
            var gitHubOAuth2Client = new GitHubOAuth2Client("something", "something");

            // Act
            // Assert
            Assert.Equal("github", gitHubOAuth2Client.ProviderName);
        }
 public static void Authenticate()
 {
     ms = new GitHubOAuth2Client(Configuration.GitHubOauthClientId, Configuration.GitHubOauthClientSecret, "GitHubLogin", "user:email,read:org");
     new OpenAuthSecurityManager(new HttpContextWrapper(HttpContext.Current),
                                 ms, OAuthDataProvider.Instance).RequestAuthentication(Configuration.GitHubOauthRedirect);
 }