Hi !
I must often run the 1300+ tests of zena and I would really like to
see some kind of progression % instead of just dots.
I have seen that there is a tk UI in test/unit but did not found a way
to use it.
Thanks for your help.
Gaspard
Hi !
I must often run the 1300+ tests of zena and I would really like to
see some kind of progression % instead of just dots.
I have seen that there is a tk UI in test/unit but did not found a way
to use it.
Thanks for your help.
Gaspard
On Sep 24, 11:03 am, Gaspard B. [email protected] wrote:
Hi !
I must often run the 1300+ tests of zena and I would really like to
see some kind of progression % instead of just dots.I have seen that there is a tk UI in test/unit but did not found a way
to use it.
Check out the current turn repo (ie. this version has not been
released yet)
http://github.com/TwP/turn/tree/master/lib
Run it with the --solo option and you’ll see a progress bar.
Progress bar doesn’t work for normal run mode yet, and it still needs
some work so the end user has better control of the output options.
But it’s getting there.
T.
I cloned the repository and did “rake gem”, “rake gem:install”
Using “require ‘turn’” in the testhelp.rb file works fine. I tested
with/without ‘turn’ to see the speed hit:
I ran the 1300+ tests without run: 6m23
With run: 6m28
(In both cases, no test failure).
That’s great it takes very little time and it gives a direct hint on
failed tests.
The --solo option to display a progress bar does not seem to work (the
progress bar … is not progressing).
Feature request
Is it possible to view a % of tests executed somewhere during the
PASS, FAIL listing ?
Thanks
Gaspard
Le 24 sept. 08 à 17:16, Trans a écrit :
On Sep 24, 12:18 pm, Gaspard B. [email protected] wrote:
failed tests.
The --solo option to display a progress bar does not seem to work (the
progress bar … is not progressing).
Hmm… that sucks. It’s working for me. It just hangs?
What system are you running? Version of Ruby? And I assume you have
Facets installed?
Is “zena” a public project? If so I could download it and try to see
what’s the issue is.
Feature request
Is it possible to view a % of tests executed somewhere during the
PASS, FAIL listing ?
Possibly, I’ll look into it.
T.
Le 24 sept. 08 à 18:35, Trans a écrit :
(In both cases, no test failure).
That’s great it takes very little time and it gives a direct hint on
failed tests.The --solo option to display a progress bar does not seem to work
(the
progress bar … is not progressing).Hmm… that sucks. It’s working for me. It just hangs?
I triedWhat system are you running? Version of Ruby? And I assume you have
Facets installed?
It’s related to zena… It works fine in irb.
pb = ProgressBar.new(‘pbtest’, 100)
=> (ProgressBar: 0/100)
irb(main):023:0> (1…100).to_a.each do
irb(main):024:1* pb.inc
irb(main):025:1> sleep(1)
irb(main):026:1> end
works fine.
Is “zena” a public project? If so I could download it and try to see
what’s the issue is.
project: http://zenadmin.org
sources: GitHub - zena/zena: zena is a state-of-the-art CMS (content managment system) based on Ruby on Rails with a focus on usability, ease of customization and web 2.0 goodness (application like behaviour).
It could come from zena (the testing stuff has been largely adapted
from rails). I started to hack around and see if I could display the
ProgressBar. The problem seems to be that the run_count is 0.
Feature request
Is it possible to view a % of tests executed somewhere during the
PASS, FAIL listing ?
I’ll try to implement an option to display the ProgressBar instead of
test list (once the ProgressBar works).
Possibly, I’ll look into it.
T.
Gaspard
It’s nice trying to test zena, but installing all the proper
dependencies is quite some work… The problem you are facing is
related to gettext. Your version is 1.93 and from the README file:
Does not work with gettext > 1.90.0 or RedCloth > 3.x
(I do not know what this issue is exactly about but I won’t work on a
fix until we move to rails 2 for the 1.0 release)
Gaspard
Well, I could only get so far. I get the following when running ‘rake
test’:
trans@logisys:zena$ rake test
(in /home/trans/programs/vendor/zena)
** zena 0.9.0 r1001 starting
** WARNING: drb server not running. Upload progress will not work.
ImageMagick not found. Using dummy.
** zena 0.9.0 r1001 starting
** WARNING: drb server not running. Upload progress will not work.
ImageMagick not found. Using dummy.
/usr/bin/ruby1.8 -Ilib:test “/usr/lib/ruby/gems/1.8/gems/rake-0.8.1/
lib/rake/rake_test_loader.rb” “test/functional/
discussion_controller_test.rb” “test/functional/
comments_controller_test.rb” “test/functional/
virtual_classes_controller_test.rb” “test/functional/
data_entries_controller_test.rb” “test/functional/
calendar_controller_test.rb” “test/functional/
version_controller_test.rb” “test/functional/
groups_controller_test.rb” “test/functional/search_controller_test.rb”
“test/functional/documents_controller_test.rb” “test/functional/
note_controller_test.rb” “test/functional/
relations_controller_test.rb” “test/functional/
session_controller_test.rb” “test/functional/
application_controller_test.rb” “test/functional/
sites_controller_test.rb” “test/functional/links_controller_test.rb”
“test/functional/users_controller_test.rb” “test/functional/
preferences_controller_test.rb” “test/functional/
iformats_controller_test.rb” “test/functional/
nodes_controller_test.rb”
** zena 0.9.0 r1001 starting
** WARNING: drb server not running. Upload progress will not work.
ImageMagick not found. Using dummy.
/home/trans/programs/vendor/zena/vendor/rails/activerecord/lib/…/…/
activesupport/lib/active_support/core_ext/module/aliasing.rb:31:in
alias_method': undefined method
label’ for class
ActionView::Helpers::FormBuilder' (NameError) from /home/trans/programs/vendor/zena/vendor/rails/activerecord/ lib/../../activesupport/lib/active_support/core_ext/module/aliasing.rb: 31:in
alias_method_chain’
from /usr/lib/ruby/gems/1.8/gems/gettext-1.93.0/lib/gettext/rails.rb:
317
from /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:32:in
gem_original_require' from /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:32:in
require’
from /home/trans/programs/vendor/zena/vendor/rails/activerecord/
lib/…/…/activesupport/lib/active_support/dependencies.rb:495:in
require' from /home/trans/programs/vendor/zena/vendor/rails/activerecord/ lib/../../activesupport/lib/active_support/dependencies.rb:342:in
new_constants_in’
from /home/trans/programs/vendor/zena/vendor/rails/activerecord/
lib/…/…/activesupport/lib/active_support/dependencies.rb:495:in
require' from /home/trans/programs/vendor/zena/app/controllers/application.rb: 1 ... 18 levels... from /usr/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake/ rake_test_loader.rb:5:in
load’
from /usr/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake/
rake_test_loader.rb:5
from /usr/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake/
rake_test_loader.rb:5:in `each’
from /usr/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake/
rake_test_loader.rb:5
/usr/bin/ruby1.8 -Ilib:test “/usr/lib/ruby/gems/1.8/gems/rake-0.8.1/
lib/rake/rake_test_loader.rb” “test/integration/navigation_test.rb”
“test/integration/multiple_hosts_test.rb” “test/integration/
multiversion_test.rb”
** zena 0.9.0 r1001 starting
** WARNING: drb server not running. Upload progress will not work.
ImageMagick not found. Using dummy.
/home/trans/programs/vendor/zena/vendor/rails/activerecord/lib/…/…/
activesupport/lib/active_support/core_ext/module/aliasing.rb:31:in
alias_method': undefined method
label’ for class
ActionView::Helpers::FormBuilder' (NameError) from /home/trans/programs/vendor/zena/vendor/rails/activerecord/ lib/../../activesupport/lib/active_support/core_ext/module/aliasing.rb: 31:in
alias_method_chain’
from /usr/lib/ruby/gems/1.8/gems/gettext-1.93.0/lib/gettext/rails.rb:
317
from /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:32:in
gem_original_require' from /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:32:in
require’
from /home/trans/programs/vendor/zena/vendor/rails/activerecord/
lib/…/…/activesupport/lib/active_support/dependencies.rb:495:in
require' from /home/trans/programs/vendor/zena/vendor/rails/activerecord/ lib/../../activesupport/lib/active_support/dependencies.rb:342:in
new_constants_in’
from /home/trans/programs/vendor/zena/vendor/rails/activerecord/
lib/…/…/activesupport/lib/active_support/dependencies.rb:495:in
require' from /home/trans/programs/vendor/zena/app/controllers/application.rb: 1 ... 18 levels... from /usr/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake/ rake_test_loader.rb:5:in
load’
from /usr/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake/
rake_test_loader.rb:5
from /usr/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake/
rake_test_loader.rb:5:in each' from /usr/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake/ rake_test_loader.rb:5 Unknown database 'zena_test' /home/trans/programs/vendor/zena/config/environment.rb:107:in
real_connect’
/home/trans/programs/vendor/zena/config/environment.rb:107:in
connect' /home/trans/programs/vendor/zena/vendor/rails/activerecord/lib/ active_record/connection_adapters/mysql_adapter.rb:158:in
initialize’
/home/trans/programs/vendor/zena/vendor/rails/activerecord/lib/
active_record/connection_adapters/mysql_adapter.rb:82:in new' /home/trans/programs/vendor/zena/vendor/rails/activerecord/lib/ active_record/connection_adapters/mysql_adapter.rb:82:in
mysql_connection’
/home/trans/programs/vendor/zena/vendor/rails/activerecord/lib/
active_record/connection_adapters/abstract/connection_specification.rb:
262:in send' /home/trans/programs/vendor/zena/vendor/rails/activerecord/lib/ active_record/connection_adapters/abstract/connection_specification.rb: 262:in
connection=’
/home/trans/programs/vendor/zena/vendor/rails/activerecord/lib/
active_record/connection_adapters/abstract/connection_specification.rb:
230:in retrieve_connection' /home/trans/programs/vendor/zena/vendor/rails/activerecord/lib/ active_record/connection_adapters/abstract/connection_specification.rb: 78:in
connection_without_query_cache’
/home/trans/programs/vendor/zena/vendor/rails/activerecord/lib/
active_record/query_cache.rb:76:in query_caches' /home/trans/programs/vendor/zena/vendor/rails/activerecord/lib/ active_record/query_cache.rb:80:in
query_cache’
/home/trans/programs/vendor/zena/vendor/rails/activerecord/lib/
active_record/query_cache.rb:107:in connection' /home/trans/programs/vendor/zena/vendor/rails/railties/lib/tasks/ databases.rake:120 /usr/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:546:in
call’
/usr/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:546:in execute' /usr/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:541:in
each’
/usr/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:541:in execute' /usr/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:508:in
invoke_with_call_chain’
…
T.
On Sep 25, 3:50 am, Gaspard B. [email protected] wrote:
How do you pass options to “turn” when you use the require ‘turn’
method ?
Yep. That is on the “TODO” list. Not sure yet how that will pan out,
though I assume we will have to either use global var(s) or allow for
a config file.
I’ll do some work on this today. If I can easily do so I want to
separate all output into a separate class that all the runners can
share.
T.
Did you receive my pull request from github ?
I passed options using class variables.
Gaspard
I start working today and manually included the test count, the
progress bar just… works !
I must find why the test count is ‘0’ in zena…
My hack to display the progress bar (it still shows failed tests)
instead of the list is also working. I will cleanup and try to enable
it only through an option. I’ll then post the changes to github.com/
gaspard/turn for you to see. My question is:
How do you pass options to “turn” when you use the require ‘turn’
method ?
Gaspard
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.
Sponsor our Newsletter | Privacy Policy | Terms of Service | Remote Ruby Jobs