Thanks Sven!<div><br></div><div>I have updated my test code and uploaded the new version to Squeaksource and updated the blog entry to reflect the changes as well.</div><div><br></div><div>I'll look at using the Zinc Seaside adaptor was well. (It'd be nice to have the tests run regardless of whether there was already a Seaside server up and running.)</div>
<div><br></div><div>TF<br><br><div class="gmail_quote">On Thu, Jan 20, 2011 at 12:33 PM, Sven Van Caekenberghe <span dir="ltr"><<a href="mailto:sven@beta9.be">sven@beta9.be</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Hey Tony,<br>
<div class="im"><br>
On 20 Jan 2011, at 19:18, Tony Fleig wrote:<br>
<br>
> I just tried it and it seemd to work:<br>
><br>
> <a href="http://www.tonyfleig.com/smallthoughts/blog/seasideautomatedtesting" target="_blank">http://www.tonyfleig.com/smallthoughts/blog/seasideautomatedtesting</a><br>
><br>
> There's an updated version usinf Zinc in place of WebClient here:<br>
><br>
> <a href="http://www.tonyfleig.com/smallthoughts/blog/seasideautomatedtesting2" target="_blank">http://www.tonyfleig.com/smallthoughts/blog/seasideautomatedtesting2</a><br>
><br>
> Let me know if it still doesn't work for you.<br>
<br>
</div>This is great!<br>
<br>
Since our last discussion, I was interested to see how the redirects went and I saw that sadly you still had to them manually. So I decided to load all your code and to try to find out what went wrong. (BTW, I was already planning to check out TFLogin, so this was a good first step.)<br>
<br>
I found the problem and commited a new version of Zn fixing the problem.<br>
<br>
You could simplify the use of Zn in your code as follows:<br>
<br>
TLTest>>#setup<br>
<br>
"...."<br>
client := (ZnHttpClient new).<br>
client settings followRedirect: true. "actually not needed since this is the default"<br>
client settings timeout: 5.<br>
<br>
TLTest>>#clickOn:in:with:<br>
<br>
"..."<br>
response := (client post: url data: args).<br>
"response isRedirect ifTrue: [<br>
url := self baseUrl, (response location).<br>
response := client get: url ]."<br>
^ response contents<br>
<br>
(I added some newer API in the commented out section). This could further be simplified to:<br>
<br>
^ (client post: url data: args) contents<br>
<br>
All TF-Login test are/remain green with these changes.<br>
<font color="#888888"><br>
Sven<br>
</font><br>
PS: I also applied a small fix to actually honor the timeout ;-)<br>
<br>
BTW: There is also a Zinc-Seaside adaptor, so you could use the Zn server part as well.<br>
<div><div></div><div class="h5"><br>
<br>
_______________________________________________<br>
seaside mailing list<br>
<a href="mailto:seaside@lists.squeakfoundation.org">seaside@lists.squeakfoundation.org</a><br>
<a href="http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside" target="_blank">http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside</a><br>
</div></div></blockquote></div><br></div>