Skip to content

Instantly share code, notes, and snippets.

@joliss
joliss / gist:772968
Created January 10, 2011 16:17
[devise] output of "rake"
(in /home/jo/src/devise)
(in /home/jo/src/devise)
/usr/bin/ruby1.9.1 -I"lib:lib:test" "/var/lib/gems/1.9.1/gems/rake-0.8.7/lib/rake/rake_test_loader.rb" "test/models_test.rb" "test/routes_test.rb" "test/devise_test.rb" "test/generators/install_generator_test.rb" "test/generators/views_generator_test.rb" "test/generators/mongoid_generator_test.rb" "test/generators/active_record_generator_test.rb" "test/mailers/confirmation_instructions_test.rb" "test/mailers/unlock_instructions_test.rb" "test/mailers/reset_password_instructions_test.rb" "test/failure_app_test.rb" "test/omniauth/url_helpers_test.rb" "test/models/validatable_test.rb" "test/models/rememberable_test.rb" "test/models/confirmable_test.rb" "test/models/lockable_test.rb" "test/models/database_authenticatable_test.rb" "test/models/recoverable_test.rb" "test/models/encryptable_test.rb" "test/models/trackable_test.rb" "test/models/timeoutable_test.rb" "test/models/token_authenticatable_test.rb" "test/encryptors_test.rb" "test/test_helpers_test.rb" "test/
@joliss
joliss / gist:774413
Created January 11, 2011 13:39
devise: Output of "rake"
(in /home/jo/src/devise)
(in /home/jo/src/devise)
/usr/bin/ruby1.9.1 -I"lib:lib:test" "/var/lib/gems/1.9.1/gems/rake-0.8.7/lib/rake/rake_test_loader.rb" "test/models_test.rb" "test/routes_test.rb" "test/devise_test.rb" "test/generators/install_generator_test.rb" "test/generators/views_generator_test.rb" "test/generators/mongoid_generator_test.rb" "test/generators/active_record_generator_test.rb" "test/mailers/confirmation_instructions_test.rb" "test/mailers/unlock_instructions_test.rb" "test/mailers/reset_password_instructions_test.rb" "test/failure_app_test.rb" "test/omniauth/url_helpers_test.rb" "test/models/validatable_test.rb" "test/models/rememberable_test.rb" "test/models/confirmable_test.rb" "test/models/lockable_test.rb" "test/models/database_authenticatable_test.rb" "test/models/recoverable_test.rb" "test/models/encryptable_test.rb" "test/models/trackable_test.rb" "test/models/timeoutable_test.rb" "test/models/token_authenticatable_test.rb" "test/encryptors_test.rb" "test/test_helpers_test.rb" "test/
@joliss
joliss / gist:1071909
Created July 8, 2011 14:06
bundle install output
Updating git://github.com/plataformatec/devise.git
Fetching source index for http://rubygems.org/
Using rake (0.9.2)
Using abstract (1.0.0)
Using activesupport (3.0.7)
Using builder (2.1.2)
Using i18n (0.5.0)
Using activemodel (3.0.7)
Using erubis (2.6.6)
Using rack (1.2.3)
@joliss
joliss / gist:1086397
Created July 16, 2011 14:22
strace -fv start mysql (last messages)
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7863000
read(3, "# Locale name alias data base.\n#"..., 4096) = 2570
read(3, "", 4096) = 0
close(3) = 0
munmap(0xb7863000, 4096) = 0
open("/usr/share/locale/en_US.UTF-8/LC_MESSAGES/upstart.mo", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/share/locale/en_US.utf8/LC_MESSAGES/upstart.mo", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/share/locale/en_US/LC_MESSAGES/upstart.mo", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/share/locale/en.UTF-8/LC_MESSAGES/upstart.mo", O_RDONLY) = -1 ENOENT (No such file or directory)
open("/usr/share/locale/en.utf8/LC_MESSAGES/upstart.mo", O_RDONLY) = -1 ENOENT (No such file or directory)
1) Capybara::Session with selenium driver it should behave like session it should behave like check#check should check a checkbox by id
Failure/Error: @session.check("form_pets_cat")
Element cannot be scrolled into view:[object HTMLInputElement]
# ./lib/capybara/selenium/node.rb:49:in `click'
# ./lib/capybara/selenium/node.rb:79:in `resynchronize'
# ./lib/capybara/selenium/driver.rb:65:in `resynchronize'
# ./lib/capybara/selenium/node.rb:79:in `resynchronize'
# ./lib/capybara/selenium/node.rb:49:in `click'
# ./lib/capybara/selenium/node.rb:24:in `set'
# ./lib/capybara/node/element.rb:75:in `set'
@joliss
joliss / gist:1560935
Created January 4, 2012 16:52
"docElement is null" failures
1) Capybara::Session with selenium driver it should behave like session it should behave like within#within with CSS selector should accept additional options
Failure/Error: @session.body.should include('Bar')
docElement is null
# [remote server] file:///tmp/webdriver-profile20120104-9414-13b1vry/extensions/[email protected]/components/driver-component.js -> file:///tmp/webdriver-profile20120104-9414-13b1vry/extensions/[email protected]/components/firefoxDriver.js:297:in `unknown'
# [remote server] file:///tmp/webdriver-profile20120104-9414-13b1vry/extensions/[email protected]/components/command_processor.js:9942:in `unknown'
# [remote server] file:///tmp/webdriver-profile20120104-9414-13b1vry/extensions/[email protected]/components/command_processor.js:9947:in `unknown'
# [remote server] file:///tmp/webdriver-profile20120104-9414-13b1vry/extensions/[email protected]/components/command_processor.js:9898:in `unknown'
# ./lib/capybara/selenium/d
diff --git a/app/helpers/konacha/specs_helper.rb b/app/helpers/konacha/specs_helper.rb
index 9a9ea72..e6d937f 100644
--- a/app/helpers/konacha/specs_helper.rb
+++ b/app/helpers/konacha/specs_helper.rb
@@ -5,7 +5,10 @@ module Konacha
asset_paths.asset_for(spec.asset_name, "js").to_a
end.flatten.uniq.map(&:logical_path)
- javascript_include_tag *assets, :body => true
+ p assets
@joliss
joliss / gist:2331836
Created April 7, 2012 20:15
"this" working in Mocha 1.0.0 (bundled with Konacha 1.0.0)
describe 'Klondike Controllers', ->
beforeEach ->
@gameController = new App.Controllers.KlondikeTurnOne
it 'has widgets', ->
console.log @gameController
assert.ok $('#konacha .redealImage').length
@joliss
joliss / gist:2688447
Created May 13, 2012 13:21
selenium-webdriver disabled attribute
# Based on jarib's template: https://gist.github.com/1024843
require 'rubygems'
require 'selenium-webdriver'
path = File.expand_path("test.html")
File.open(path, "w") { |io| io << DATA.read }
browser = Selenium::WebDriver.for :firefox # replace :firefox with the browser you're having trouble with
$ bundle install
Using rake (0.9.2.2)
Using addressable (2.2.7)
Using colored (1.2)
Using rack (1.4.1)
Using thor (0.14.6)
Using ember-docs (0.1) from https://github.com/emberjs/docs-generator.git (at master)
NoMethodError: undefined method `[]' for nil:NilClass
An error occured while installing ember-docs (0.1), and Bundler cannot continue.
Make sure that `gem install ember-docs -v '0.1'` succeeds before bundling.