Exemplo n.º 1
0
        public async Task TestRegister()
        {
            var client = new MastodonDynamicClient(_Host, _AccessToken);

            var result = await client.Register("MastodonClient", OAuthScope.of(Scope.Read, Scope.Write, Scope.Follow));

            Assert.IsNotNull(result.id);

            Assert.IsNotNull(result.client_id);

            Assert.IsNotNull(result.client_secret);

            Assert.IsNotNull(result.auth_url);

            Process.Start((string)result.auth_url);
        }
Exemplo n.º 2
0
        public async Task TestRegister()
        {
            var client = new MastodonSharpClient(_Host, _AccessToken);

            var result = await client.Register("MastodonClient", OAuthScope.of(Scope.Read, Scope.Write, Scope.Follow));

            Assert.IsNotNull(result.Id);

            Assert.IsNotNull(result.ClientId);

            Assert.IsNotNull(result.ClientSecret);

            Assert.IsNotNull(result.AuthUrl);

            Assert.IsNotNull(result.RedirectUri);

            Assert.IsNotNull(result.Scope);

            Assert.IsNotNull(result.Instance);
        }