Beispiel #1
0
        public static void Initialize(TestContext tcontext)
        {
            // Set credentials from client-ID
            InstagramCredentials instaCre = new InstagramCredentials("6a5985a97e0842d3a97c80d29a761f83");
            IAuthContext         context  = AuthFlow.InitAuth(instaCre, "http://www.google.es");

            var token = GetTokenFromUrl(context.AuthorizationURL, "<username>", "<password>");

            // Set the credentials
            AuthFlow.CreateCredentialsFromAccesToken(token);

            AuthFlow.SetUserCredentials();

            Assert.IsNotNull(UserManager.GetAuthenticatedUser());
        }