Пример #1
0
        public void GetSites()
        {
            using (var context = new AsynchronusTestContext(this))
            {
                IEnumerable <Site> received  = null;
                ApiException       exception = null;

                bool completed = false;
                EnqueueCallback(() =>
                {
                    AuthClient.GetSites(results =>
                    {
                        received  = results;
                        completed = true;
                    },
                                        error =>
                    {
                        exception = error;
                        completed = true;
                    });
                });
                EnqueueConditional(() => completed);
                EnqueueCallback(() => Assert.IsNull(exception));
                EnqueueCallback(() => Assert.IsNotNull(received));
            }
        }
Пример #2
0
        public void GetSites_ContainsStyling()
        {
            var sites = AuthClient.GetSites();

            Assert.IsNotNull(sites);
            foreach (var site in sites)
            {
                Assert.IsNotNull(site.MainSite.Styling);
            }
        }
Пример #3
0
        public void GetSites()
        {
            var sites = AuthClient.GetSites();

            Assert.IsNotNull(sites);
        }