Permalink
Browse files

get selenium cucumber tests running

add all non-photocracy cucumber tests

remove params for form_tag block

remove debugging text

update email_spec gem to remove DelayedJob warning

use bundler bin rake for test:db:load

use bundle exec for rake task

add trace to rake call

upgrade email_spec to most recent

fix warning about errors.each block

revert to email_spec 0.4.0

capitalize error for user on create page
  • Loading branch information...
1 parent e78ed8a commit a19dbb63f8a3801465b0024ecf351df11687e6e0 @lukebaker lukebaker committed Nov 5, 2012
View
@@ -10,8 +10,10 @@ before_install:
- tar -xf phantomjs-1.7.0-linux-i686.tar.bz2
- sudo rm -rf /usr/local/phantomjs
- sudo mv phantomjs-1.7.0-linux-i686 /usr/local/phantomjs
+ - "export DISPLAY=:99.0"
+ - "sh -e /etc/init.d/xvfb start"
before_script:
- - rake db:test:load
+ - bundle exec rake --trace db:test:load
- export PREV_BUNDLE_GEMFILE=$BUNDLE_GEMFILE
- export BUNDLE_GEMFILE=''
- git clone --depth=100 --quiet git://github.com/allourideas/pairwise-api.git
@@ -24,5 +26,5 @@ before_script:
- bundle exec ./script/server -p 4000 -d
- cd ../
- export BUNDLE_GEMFILE=$PREV_BUNDLE_GEMFILE
-script: bundle exec spec spec/integration spec/controllers/questions_controller_spec.rb && RAILS_ENV='cucumber' bundle exec cucumber --no-profile -f progress --require features --require lib features/voting/voting.feature
+script: bundle exec spec spec/integration spec/controllers/questions_controller_spec.rb && RAILS_ENV='cucumber' bundle exec cucumber --no-profile -f progress --require features --require lib features/[afiruvw]*
bundler_args: --local
@@ -126,7 +126,7 @@
%button.close{:"data-dismiss" => 'modal'} x
%h2= t('questions.edit_question')
.modal-body
- - form_tag update_name_question_path(@earl), :method => :put do |f|
+ - form_tag update_name_question_path(@earl), :method => :put do
%p
=t('questions.your_current_question_text', :question_text => h(@question.name), :"1" => '<span class="question-name">', :"_1" => '</span>')
%p
@@ -18,11 +18,11 @@
%h2=t('questions.new.error.registration')
%br
%ul
- -@user.errors.each do |error|
- - if error.join(' ') =~ /Email has already been taken/i
+ -@user.errors.each do |field, error|
+ - if field =~ /Email/i && error =~ /has already been taken/i
%li= t('questions.new.error.already_taken') + " " + link_to(t('questions.new.error.already_taken_link'), '/sign_in')
- else
- %li= error.join(' ').capitalize
+ %li= "#{field} #{error}".capitalize
%h3= t('questions.new.step1')
%p
@@ -128,7 +128,6 @@
end
Given /^I save the current (.*) (choices|choice|photos)?$/ do |side,type|
- puts "the type is #{type}"
if type == "photos"
@photocracy_mode = true
set_active_resource_credentials

0 comments on commit a19dbb6

Please sign in to comment.