Mercurial > altnet-hispano
view Agendas/trunk/src/Agendas.Configurations.Tests/Read_configuration.cs @ 243:59f8fa2f835e
Ticket 177: Valor de Duración de VAN en 0.
author | juanjose.montesdeocaarbos |
---|---|
date | Thu, 06 Oct 2011 08:13:05 -0300 |
parents | 734d3f0853bf |
children |
line wrap: on
line source
using AltNetHispano.Agendas.Configurations; using NUnit.Framework; namespace Agendas.Configurations.Tests { [TestFixture] public class Read_configuration { [Test] public void Read() { var section = AgendasConfigurationManager.Publicadores; Assert.IsNotNull(section); } [Test] public void Read_twitter() { var publicadores = AgendasConfigurationManager.Publicadores; Assert.IsNotNull(publicadores); Assert.IsNotNull(publicadores.Twitter); var twitter = publicadores.Twitter; Assert.AreEqual(true, twitter.Enabled); Assert.IsNotNull(twitter.SignIn); Assert.AreEqual("consumerKey1", twitter.SignIn.ConsumerKey); Assert.AreEqual("consumerSecret1", twitter.SignIn.ConsumerSecret); Assert.AreEqual("consumerKey2", twitter.SendTwitter.ConsumerKey); Assert.AreEqual("consumerSecret2", twitter.SendTwitter.ConsumerSecret); Assert.AreEqual("accessToken2", twitter.SendTwitter.AccessToken); Assert.AreEqual("accessTokenSecret2", twitter.SendTwitter.AccessTokenSecret); } [Test] public void Read_blog() { var publicadores = AgendasConfigurationManager.Publicadores; Assert.IsNotNull(publicadores); Assert.IsNotNull(publicadores.Blog); var blog = publicadores.Blog; Assert.AreEqual(true, blog.Enabled); Assert.IsNotNull(blog.Writer); Assert.AreEqual("blogName", blog.Writer.BlogName); Assert.AreEqual("blogWriterMasterKey", blog.Writer.BlogWriterMasterKey); Assert.AreEqual("postWriterServiceUrl", blog.Writer.PostWriterServiceUrl); } [Test] public void Read_google() { var publicadores = AgendasConfigurationManager.Publicadores; Assert.IsNotNull(publicadores); Assert.IsNotNull(publicadores.Google); var google = publicadores.Google; Assert.AreEqual(true, google.Enabled); Assert.IsNotNull(google.Calendar); Assert.AreEqual("altnethispano.desa@gmail.com", google.Calendar.UserName); Assert.AreEqual("altnethispano.desa@gmail.com", google.Calendar.CalendarId); Assert.AreEqual("password", google.Calendar.Password); } } }