install phantomjs
brew install phantomjs
Gemfile:
group :test do
gem 'poltergeist'
gem 'database_cleaner'
$( document ).ready(function() { | |
//whatever | |
}); | |
// Shorthand for $( document ).ready() | |
$(function() { | |
//whatever | |
}); |
// FFmpeg settings for vimeo.com | |
// ============================= | |
// Trying to find the best settings for encoding videos as described here: http://vimeo.com/help/compression | |
// | |
// Input file: MTS | |
// Video: H264, 1920x1080, 50fps | |
// Audio: A52 Audio (aka AC3), Stereo, 48kHz, 256kbps | |
ffmpeg -i input.mts -vcodec libx264 -acodec aac -strict experimental -vpre hq -s hd720 -b 5000k -ab 320k -r 25 -g 25 -threads 0 output.mp4 |
install phantomjs
brew install phantomjs
Gemfile:
group :test do
gem 'poltergeist'
gem 'database_cleaner'
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
ActiveRecord cheat sheet / EXAMPLES | |
INSTALL | |
======= | |
$ gem install activerecord | |
in GEMFILE: gem ‘activerecord’ | |
REQUIRE | |
======= | |
require ‘active_record’ |
=Navigating= | |
visit('/projects') | |
visit(post_comments_path(post)) | |
=Clicking links and buttons= | |
click_link('id-of-link') | |
click_link('Link Text') | |
click_button('Save') | |
click('Link Text') # Click either a link or a button | |
click('Button Value') |
=Navigating= | |
visit('/projects') | |
visit(post_comments_path(post)) | |
=Clicking links and buttons= | |
click_link('id-of-link') | |
click_link('Link Text') | |
click_button('Save') | |
click('Link Text') # Click either a link or a button | |
click('Button Value') |