Search the web
Sign In
New User? Sign Up
TestFirstUserInterfaces
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Message search is now enhanced, find messages faster. Take it for a spin.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
Re: [agile-testing] Unit Testing the Presentation Layer   Message List  
Reply | Forward Message #1045 of 1051 |
Re: [TFUI] Re: [agile-testing] Unit Testing the Presentation Layer

Re: Can ASP render a page back as a string.
Absolutely! Its call Response.Write, just pipe it out to whatever channel you
like :)

Regards,

Miguel de Sousa




________________________________
From: Phlip <phlip2005@...>
To: agile-testing@yahoogroups.com; testfirstuserinterfaces@yahoogroups.com
Sent: Friday, 12 June, 2009 13:48:10
Subject: [TFUI] Re: [agile-testing] Unit Testing the Presentation Layer





John Overbaugh wrote:

> I'm not sure this answers my question. What I'm looking for are 1) best
> practices around unit testing the presentation layer

Unit testing the presentation layer should treat the test targets the same as
any other layer would test them. In web programming, a web page is a big string.
If you had a business-layer module that produced a big string, you would _unit_
test it by parsing the string back using the same tools as generated it.

Testing thru-the-server AND thru-the-browser is slow and fragile. Only do it
_after_ you can TDD the source directly, because that's where most development
should happen.

> and 2) ideas around
> headless testing within the presentation layer (if it's at all
> possible). I am quite familiar with Selenium, WatiN, etc.and how to use
> them even against Ajax (which is, I believe, what your offering). I'm
> trying to take it to the next level and create a good, reliable,
> headless unit test for my dev team (if it can be done).

Again: Can ASP render a page back as a string, ready to be parsed? If not, then
ask MS why. The answer is probably inexcusable vendor lock-in.

--
Phlip






[Non-text portions of this message have been removed]




Fri Jun 12, 2009 4:17 am

migdesousa
Offline Offline
Send Email Send Email

Forward
Message #1045 of 1051 |
Expand Messages Author Sort by Date

... Will ASP allow you to cook a web page without sending it over the wire? If you Mock The Server, you can then test - even TDD - by writing assertions that...
Phlip
phlipcpp
Offline Send Email
Jun 12, 2009
2:24 am

... Unit testing the presentation layer should treat the test targets the same as any other layer would test them. In web programming, a web page is a big...
Phlip
phlipcpp
Offline Send Email
Jun 12, 2009
3:48 am

Re: Can ASP render a page back as a string. Absolutely! Its call Response.Write, just pipe it out to whatever channel you like :) Regards, Miguel de Sousa ...
miguel de sousa
migdesousa
Offline Send Email
Jun 12, 2009
4:45 am

... Could anyone here who's familiar with both ASP's Response.Write, and with Rails's ActionController::TestCase's get() method, write a little pseudocode here...
Phlip
phlipcpp
Offline Send Email
Jun 12, 2009
4:49 am

... To add a new feature, you should generally add it at the business layer first. The goal will be that anything a user can do to the View, a unit test can...
Phlip
phlipcpp
Offline Send Email
Jun 12, 2009
2:25 pm

... Here's a metaphor - the Golden Spike at Promontory Point, Utah, where the Union Pacific and Central Pacific railways met for our first intercontinental...
Phlip
phlipcpp
Offline Send Email
Jun 16, 2009
7:05 pm
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help