using System.Xml;
using MusicMetaTagger.Client.AllMusicGuide.RemoteDataAccess.Client;
using NUnit.Framework;

namespace MusicMetaTagger.Client.AllMusicGuide.Tests.RemoteDataAccess.Client
{
	public class GoogleXmlClient : XmlClientBase
	{
		public override XmlDocument Read(string criteria)
		{
			return ReadFromCriteria("http://google.com/?q={0}", criteria);
		}
	}

	[TestFixture]
	public class XmlClientBaseTests
	{
		[Test, Explicit]
		public void ReadsDocument()
		{
			var client = new GoogleXmlClient();
			var xmlDocument = client.Read("banana");
			Assert.That(xmlDocument.InnerText.Contains("banana"));
		}
	}
}
