* Rename and reorganize post fetcher to fix autoloading, also let it use Faradays default connection so we get nice redirects * Add initializer to load libs at a central place * added lib dir to autoload_once paths to increase thread safety * Moved lib/exceptions.rb to lib/diaspora/ to conform namespacing
37 lines
677 B
Ruby
37 lines
677 B
Ruby
module DebuggingCukeHelpers
|
|
def start_debugging
|
|
require 'debug'
|
|
debugger
|
|
true
|
|
end
|
|
end
|
|
|
|
World(DebuggingCukeHelpers)
|
|
|
|
|
|
When 'I debug' do
|
|
start_debugging
|
|
end
|
|
|
|
When /^I wait for (\d+) seconds?$/ do |seconds|
|
|
sleep seconds.to_i
|
|
warn "\nDELETEME - this step is for debugging, only!\n"
|
|
end
|
|
|
|
When /^I open the error console$/ do
|
|
page.driver.browser.action.
|
|
key_down(:control).
|
|
key_down(:shift).
|
|
send_keys("j").
|
|
key_up(:shift).
|
|
key_up(:control).perform
|
|
end
|
|
|
|
When /^I open the web console$/ do
|
|
page.driver.browser.action.
|
|
key_down(:control).
|
|
key_down(:shift).
|
|
send_keys("k").
|
|
key_up(:shift).
|
|
key_up(:control).perform
|
|
end
|