Ilan Berci wrote:
> Change this:
>> <% t = Time.now %>
>> <h1>Hello#index</h1>
>> <p>Find me in app/views/hello/index.rhtml</p>
>> 
>> <pre>
>> <% for i in 1..100 do %>
>>   <%= Time.now %>
>>   <%= h @ha %>
>>   <%= sanitize @ha %>
>>   <%= u @ha %>
>>   <%= @ha.to_json %>
>>   <%= strip_tags @ha %>
>> 
>>   <%= Time.now - t %>
>> 
>>   <%= 1 / (Time.now - t) %>
>> <% end %>
>> 
> to this:
> <% for i in 1..100 do %>
>   <% t = Time.now %>
>   <%= h @ha %>
>   <%= sanitize @ha %>
>   <%= u @ha %>
>   <%= @ha.to_json %>
>   <%= strip_tags @ha %>>
>   <%= 1 / (Time.now - t) %>
> <% end %>
> 
> your test is still flawed as the above poster mentioned.. but this will 
> correct the behavior you were previously seeing..
> 
> ilan

how is my test flawed?   I wasn't looking to see if each iteration takes 
different duration.  I was really try to run a simple loop and see how 
many hits the server can take per second.  be careful when you say 
people's code is flawed, as it insults people.  maybe you don't know 
about it.

-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to