This error come up when I run my cucumber test file.
Solution: the problem is because in my config.yml file I have an entry with "-".
So in my config.yml I have the following:
test_server:
member_no: -
member_name: -
year: 2014
To fix the issue, just remove the "-" from config.yml so that ruby can parse the yml file
test_server:
member_no: 00000010
member_name: cucumber
year: 2014
Thursday, July 10, 2014
Tuesday, July 1, 2014
Heroku: Permission denied (publickey)
Error:
heroku git:clone -a myapp
Cloning from app 'myapp'...
Cloning into 'myapp'...
The authenticity of host 'heroku.com (50.19.85.154)' can't be established.
RSA key fingerprint is 8b:48:5e:67:0e:c9:16:47:32:f2:87:0c:1f:c8:60:ad.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added 'heroku.com,50.19.85.154' (RSA) to the list of known hosts.
Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
Solution:
terminal:~ heroku keys:add
Could not find an existing public key.
Would you like to generate one? [Yn] y
Generating new SSH public key.
Uploading SSH public key /Users/terminal/.ssh/id_rsa.pub... done
termina:~ heroku git:clone -a myapp
Cloning from app 'myapp'...
Cloning into 'myapp'...
Fetching repository, done.
remote: Counting objects: 2405, done.
remote: Compressing objects: 100% (1323/1323), done.
Receiving objects: 12% (305/2405), 3.27 MiB | 12.00 KiB/s
.
.
.
.
Friday, August 30, 2013
did not find expected key while parsing a block mapping at line 1 column 1
I get the following error when running cucumber, ruby, capybara with selenium webdriver
It turns out that in my config.yml (features/support/config.yml) I have an extra space:
"
test_server:
base_url: http://192.168.1.10/test/
test_server2:
base_url: http://192.168.1.4/test/
"
which should be:
"
test_server:
base_url: http://192.168.1.10/test/
test_server2:
base_url: http://192.168.1.4/test/
" (no space on "test_server2")
D:\work\cucumber>bundle exec cucumber features\regression\search.feature
(<unknown>): did not find expected key while parsing a block mapping at line 1 column 1 (Psych::SyntaxError)
C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/psych.rb:206:in `parse'
C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/psych.rb:206:in `parse_stream'
C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/psych.rb:289:in `load_stream'
C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/psych/deprecated.rb:28:in `load_documents'
D:/work/cucumber/features/support/lib/configuration.rb:11:in `load'
D:/work/cucumber/features/support/lib/configuration.rb:22:in `<top (required)>'
D:/work/cucumber/features/support/env.rb:12:in `require'
D:/work/cucumber/features/support/env.rb:12:in `<top (required)>'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/rb_support/rb_language.rb:122:in `load'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/rb_support/rb_language.rb:122:in `load_code_file'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/runtime/support_code.rb:180:in `load_file'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/runtime/support_code.rb:83:in `block in load_files!'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/runtime/support_code.rb:82:in `each'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/runtime/support_code.rb:82:in `load_files!'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/runtime.rb:183:in `load_step_definitions'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/runtime.rb:42:in `run!'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/cli/main.rb:47:in `execute!'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/bin/cucumber:13:in `<top (required)>'
D:/work/cucumber/vendor/ruby/1.9.1/bin/cucumber:23:in `load'
D:/work/cucumber/vendor/ruby/1.9.1/bin/cucumber:23:in `<main>'
It turns out that in my config.yml (features/support/config.yml) I have an extra space:
"
test_server:
base_url: http://192.168.1.10/test/
test_server2:
base_url: http://192.168.1.4/test/
"
which should be:
"
test_server:
base_url: http://192.168.1.10/test/
test_server2:
base_url: http://192.168.1.4/test/
" (no space on "test_server2")
D:\work\cucumber>bundle exec cucumber features\regression\search.feature
(<unknown>): did not find expected key while parsing a block mapping at line 1 column 1 (Psych::SyntaxError)
C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/psych.rb:206:in `parse'
C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/psych.rb:206:in `parse_stream'
C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/psych.rb:289:in `load_stream'
C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/psych/deprecated.rb:28:in `load_documents'
D:/work/cucumber/features/support/lib/configuration.rb:11:in `load'
D:/work/cucumber/features/support/lib/configuration.rb:22:in `<top (required)>'
D:/work/cucumber/features/support/env.rb:12:in `require'
D:/work/cucumber/features/support/env.rb:12:in `<top (required)>'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/rb_support/rb_language.rb:122:in `load'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/rb_support/rb_language.rb:122:in `load_code_file'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/runtime/support_code.rb:180:in `load_file'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/runtime/support_code.rb:83:in `block in load_files!'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/runtime/support_code.rb:82:in `each'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/runtime/support_code.rb:82:in `load_files!'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/runtime.rb:183:in `load_step_definitions'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/runtime.rb:42:in `run!'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/lib/cucumber/cli/main.rb:47:in `execute!'
D:/work/cucumber/vendor/ruby/1.9.1/gems/cucumber-1.3.1/bin/cucumber:13:in `<top (required)>'
D:/work/cucumber/vendor/ruby/1.9.1/bin/cucumber:23:in `load'
D:/work/cucumber/vendor/ruby/1.9.1/bin/cucumber:23:in `<main>'
Tuesday, May 7, 2013
Capybara Hover Over Element
To emulate mouse hover with Capybara use the following method:
find(:css, "#menu_bar").hover
I am using capybara (2.1.0) and selenium-webdriver (2.32.1)
find(:css, "#menu_bar").hover
I am using capybara (2.1.0) and selenium-webdriver (2.32.1)
Subscribe to:
Posts (Atom)