Not sure what the protocol around failing tests are; I get a test failure here:
Scenario: I can edit file
Given I sign in as a user # features/steps/shared/authentication.rb:7
And I own project "Shop" # features/steps/shared/project.rb:11
! Given I visit project source page # features/steps/shared/paths.rb:201
~ Given I click on "Gemfile" file in repo
~ And I click button "edit"
~ Then I can edit code
Timed out waiting for response to {"name":"visit","args":["http://127.0.0.1:60821/shop/tree/master"]} /home/vagrant/.rvm/gems/ruby-1.9.3-p374/bundler/gems/poltergeist-5c2e09200107/lib/capybara/poltergeist/web_socket_server.rb:147:in `rescue in send'
If this isn't the place for these kinds of things please let me know where they should go. I looked on the wiki but didn't see any links to a build system to see if it was just me...
Designs
Child items
...
Show closed items
Linked items
0
Link issues together to show that they're related.
Learn more.
This was against master -- I assume all tests should pass regardless though.
I've also reproduced it on 4-2-stable, and 4-1-stable. This might be a problem with my vagrant vm?
Still getting this error out of the box on vagrant, tried "bundle update", after that get:
ihalpert@ihalpert-VirtualBox:~/gitlab$ bundle exec spinachRack::File headers parameter replaces cache_control after Rack 1.5.Coverage report generated for RSpec to /home/ihalpert/gitlab/coverage. 384 / 969 LOC (39.63%) covered./home/ihalpert/gitlab/lib/api.rb:12:in `<class:API>': undefined method `error_format'for Gitlab::API:Class (NoMethodError) from /home/ihalpert/gitlab/lib/api.rb:4:in `<module:Gitlab>' from /home/ihalpert/gitlab/lib/api.rb:3:in `<top (required)>' from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-3.2.11/lib/active_support/dependencies.rb:251:in `require' from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-3.2.11/lib/active_support/dependencies.rb:251:in `block in require' from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-3.2.11/lib/active_support/dependencies.rb:236:in `load_dependency' from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-3.2.11/lib/active_support/dependencies.rb:251:in `require' from /home/ihalpert/gitlab/config/routes.rb:10:in `block in <top (required)>' from /usr/local/lib/ruby/gems/1.9.1/gems/actionpack-3.2.11/lib/action_dispatch/routing/route_set.rb:282:in `instance_exec' from /usr/local/lib/ruby/gems/1.9.1/gems/actionpack-3.2.11/lib/action_dispatch/routing/route_set.rb:282:in `eval_block' from /usr/local/lib/ruby/gems/1.9.1/gems/actionpack-3.2.11/lib/action_dispatch/routing/route_set.rb:260:in `draw' from /home/ihalpert/gitlab/config/routes.rb:3:in `<top (required)>' from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-3.2.11/lib/active_support/dependencies.rb:245:in `load' from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-3.2.11/lib/active_support/dependencies.rb:245:in `block in load' from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-3.2.11/lib/active_support/dependencies.rb:236:in `load_dependency' from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-3.2.11/lib/active_support/dependencies.rb:245:in `load' from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.11/lib/rails/application/routes_reloader.rb:40:in `block in load_paths' from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.11/lib/rails/application/routes_reloader.rb:40:in `each' from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.11/lib/rails/application/routes_reloader.rb:40:in `load_paths' from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.11/lib/rails/application/routes_reloader.rb:16:in `reload!' from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.11/lib/rails/application.rb:108:in `reload_routes!' from /usr/local/lib/ruby/gems/1.9.1/gems/devise-2.1.3/lib/devise/rails.rb:14:in `block in <class:Engine>' from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-3.2.11/lib/active_support/lazy_load_hooks.rb:34:in `call' from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-3.2.11/lib/active_support/lazy_load_hooks.rb:34:in `execute_hook' from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-3.2.11/lib/active_support/lazy_load_hooks.rb:43:in `block in run_load_hooks' from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-3.2.11/lib/active_support/lazy_load_hooks.rb:42:in `each' from /usr/local/lib/ruby/gems/1.9.1/gems/activesupport-3.2.11/lib/active_support/lazy_load_hooks.rb:42:in `run_load_hooks' from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.11/lib/rails/application/finisher.rb:52:in `block in <module:Finisher>' from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.11/lib/rails/initializable.rb:30:in `instance_exec' from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.11/lib/rails/initializable.rb:30:in `run' from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.11/lib/rails/initializable.rb:55:in `block in run_initializers' from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.11/lib/rails/initializable.rb:54:in `each' from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.11/lib/rails/initializable.rb:54:in `run_initializers' from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.11/lib/rails/application.rb:136:in `initialize!' from /usr/local/lib/ruby/gems/1.9.1/gems/railties-3.2.11/lib/rails/railtie/configurable.rb:30:in `method_missing' from /home/ihalpert/gitlab/config/environment.rb:5:in `<top (required)>' from /home/ihalpert/gitlab/features/support/env.rb:4:in `require' from /home/ihalpert/gitlab/features/support/env.rb:4:in `<top (required)>' from /usr/local/lib/ruby/gems/1.9.1/gems/spinach-0.7.0/lib/spinach/runner.rb:91:in `require' from /usr/local/lib/ruby/gems/1.9.1/gems/spinach-0.7.0/lib/spinach/runner.rb:91:in `block in require_dependencies' from /usr/local/lib/ruby/gems/1.9.1/gems/spinach-0.7.0/lib/spinach/runner.rb:90:in `each' from /usr/local/lib/ruby/gems/1.9.1/gems/spinach-0.7.0/lib/spinach/runner.rb:90:in `require_dependencies' from /usr/local/lib/ruby/gems/1.9.1/gems/spinach-0.7.0/lib/spinach/runner.rb:64:in `run' from /usr/local/lib/ruby/gems/1.9.1/gems/spinach-0.7.0/lib/spinach/cli.rb:29:in `run' from /usr/local/lib/ruby/gems/1.9.1/gems/spinach-0.7.0/bin/spinach:15:in `<top (required)>' from /usr/local/bin/spinach:23:in `load' from /usr/local/bin/spinach:23:in `<main>'
Making the following changes seems to get it running again:
diff --git a/features/steps/project/project_hooks.rb b/features/steps/project/project_hooks.rbindex 36555fb..b5a3af4 100644--- a/features/steps/project/project_hooks.rb+++ b/features/steps/project/project_hooks.rb@@ -3,7 +3,7 @@ class ProjectHooks < Spinach::FeatureSteps include SharedProject include SharedPaths include RSpec::Matchers- include RSpec::Mocks::ExampleMethods+# include RSpec::Mocks::ExampleMethods Given 'project has hook'do @hook = create(:project_hook, project: current_project)diff --git a/lib/api.rb b/lib/api.rbindex 81a5919..fc2604c 100644--- a/lib/api.rb+++ b/lib/api.rb@@ -9,7 +9,7 @@ module Gitlab end format :json- error_format :json+# error_format :json helpers APIHelpers mount Groups
And i get new problems:
Scenario: I add new hook ✔ Given I sign in as a user # features/steps/shared/authentication.rb:7 ✔ And I own project "Shop"# features/steps/shared/project.rb:11 ✔ Given I visit project hooks page # features/steps/shared/paths.rb:167! When I submit new hook # features/steps/project/project_hooks.rb:16 ~ Then I should see newly created hook stack level too deep /usr/local/lib/ruby/gems/1.9.1/gems/rspec-expectations-2.0.1/lib/rspec/matchers/method_missing.rb:6 Scenario: I test hook ✔ Given I sign in as a user # features/steps/shared/authentication.rb:7 ✔ And I own project "Shop"# features/steps/shared/project.rb:11 ✔ Given project has hook # features/steps/project/project_hooks.rb:8 ✔ And I visit project hooks page # features/steps/shared/paths.rb:167! When I click test hook button # features/steps/project/project_hooks.rb:27 ~ Then hook should be triggered stack level too deep /usr/local/lib/ruby/gems/1.9.1/gems/rspec-expectations-2.0.1/lib/rspec/matchers/method_missing.rb:6
By Administrator on 2013-02-22T15:47:10 (imported from GitLab project)
By Administrator on 2013-02-22T15:47:10 (imported from GitLab)
Probably unecessary/too much information, but...
under a RHEL distribution 4-2-stable (with the timeout increased) returns a new error: "no link with title, id or text 'edit' found"
By Administrator on 2013-02-25T18:53:09 (imported from GitLab project)
By Administrator on 2013-02-25T18:53:09 (imported from GitLab)
For those who must run on slow machines some things that I've done to get tests passing:
-The timeout increase mentioned above
-Removal of tmp directory, followed by rebuilding the test database (bundle exec rake db:setup RAILS_ENV=test && bundle exec rake db:seed_fu RAILS_ENV=test)
I still have the odd test failure; It would be much better to have a clear separation integration tests from unit tests . This could be a failure of my understanding obviously, but it seems to me anything involving capybera and poltrigeist is not strictly a unit test. More importantly they are slow enough that it makes people not able to run their tests very often.
Having integration tests is excellent, but being able to separate them out would be a great boon to all. Unless someone gets to it before me i'll try to submit a patch/pull request for this at some point.
By Administrator on 2013-02-27T14:49:06 (imported from GitLab project)
By Administrator on 2013-02-27T14:49:06 (imported from GitLab)