# HG changeset patch # User juanjose.montesdeocaarbos # Date 1312890908 10800 # Node ID 49125b681709cabbcb62d84bce2a20b8df3659c4 # Parent 37bc622980b4df2d64b078ad7d3c553c617d728c# Parent 2d02adb793225ff44f5fb6cec21839efbd1a31c1 Combinar diff -r 2d02adb79322 -r 49125b681709 Agendas/trunk/src/Agendas.Google.Test/Agendas.Google.Test.csproj --- a/Agendas/trunk/src/Agendas.Google.Test/Agendas.Google.Test.csproj Tue Aug 09 01:04:27 2011 -0400 +++ b/Agendas/trunk/src/Agendas.Google.Test/Agendas.Google.Test.csproj Tue Aug 09 08:55:08 2011 -0300 @@ -57,6 +57,7 @@ + diff -r 2d02adb79322 -r 49125b681709 Agendas/trunk/src/Agendas.Google.Test/App.config --- a/Agendas/trunk/src/Agendas.Google.Test/App.config Tue Aug 09 01:04:27 2011 -0400 +++ b/Agendas/trunk/src/Agendas.Google.Test/App.config Tue Aug 09 08:55:08 2011 -0300 @@ -10,4 +10,32 @@ + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff -r 2d02adb79322 -r 49125b681709 Agendas/trunk/src/Agendas.Google.Test/GUrlShortenerTest.cs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Agendas/trunk/src/Agendas.Google.Test/GUrlShortenerTest.cs Tue Aug 09 08:55:08 2011 -0300 @@ -0,0 +1,20 @@ +using AltNetHispano.Agendas.Google; +using NUnit.Framework; + +namespace Agendas.Google.Test +{ + [TestFixture] + [Explicit] + public class GUrlShortenerTest + { + [Test] + public void Obtener_Url_corta() + { + var gUrlShortener = new GUrlShortener(); + + var shortUrl = gUrlShortener.GetShortUrl("http://www.twitter.com"); + + Assert.AreEqual("http://goo.gl/CbHS", shortUrl); + } + } +} diff -r 2d02adb79322 -r 49125b681709 Agendas/trunk/src/Agendas.Google/Agendas.Google.csproj --- a/Agendas/trunk/src/Agendas.Google/Agendas.Google.csproj Tue Aug 09 01:04:27 2011 -0400 +++ b/Agendas/trunk/src/Agendas.Google/Agendas.Google.csproj Tue Aug 09 08:55:08 2011 -0300 @@ -58,6 +58,7 @@ + diff -r 2d02adb79322 -r 49125b681709 Agendas/trunk/src/Agendas.Google/GUrlShortener.cs --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Agendas/trunk/src/Agendas.Google/GUrlShortener.cs Tue Aug 09 08:55:08 2011 -0300 @@ -0,0 +1,18 @@ +using System; +//using GoogleAPI.UrlShortener; + +namespace AltNetHispano.Agendas.Google +{ + public class GUrlShortener + { + public string GetShortUrl(string url) + { + //TODO: Esto es utilizando la GoogleAPI.UrlShortener. + //var client = new UrlResource(); + //var response = client.Insert(new ShortenRequest { LongUrl = url }); + + //return response.Id; + throw new NotImplementedException(); + } + } +} \ No newline at end of file