Telerik blogs

Latest

For the latest product updates, please visit Release.

  • Productivity Testing

    Telerik.QuickStart.XhtmlPage is a testing tool too!

    Many a customer has asked us "What, the heck, is XhtmlPage and do I need it to run your components?"  It is an oddity in our QuickStart examples application that needs some explanation.  Atanas, the creator of the class, has already started that in his "Making ASP.NET XHTML 1.1 compliant" post. Today I was describing a testing approach on the Extreme Programming mailing list that relied on the fact that our controls render standards compliant XHTML, and you could leverage that to write tests using the XML API in .NET -- XPath is sooo convenient for that.  And then it hit me!  What...
    February 19, 2006
  • Productivity Testing

    Two types of jsUnit tests

    I am a big jsUnit fan. I can't imagine what JavaScript development would be like if that tool did not exist. We all know that code without proper unit test coverage is legacy code. It is a time bomb waiting to go off in the hands of the developer that touches it next. Over time I have noticed a pattern in my jsUnit usage. I usually wear one of two testing hats when writing tests:The browser compatibility hat. Most developers know how to do things in Internet Explorer, and Gecko-based browsers. Those differences are widely known and people are used to writing...
    January 19, 2006
  • Productivity Testing

    Poor man's ASP.NET testing

    Sometimes you have a simple page with some web controls on it.  You would like to have a simple way to make sure that the text of a status message is exactly the one you expect.  Well, it turns out that the .NET class library has a real gem that can help you.  The System.Net.WebClient class helps you request pages, post data, upload files with a simple interface.  Getting the page contents is easy: [Test]public void GetPage(){   WebClient client = new WebClient();   using (Stream dataStream = client.OpenRead(pageAddress))   {      XmlDocument document = new XmlDocument();      document.Load(dataStream);       XmlNode label = document.SelectSingleNode("//label[@id='nameLabel']");      Assert.AreEqual("Name:", label.InnerText);   }} I have taken some extra care to return valid XML,...
    August 25, 2005