Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
=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') |
Feature: Capybara Webkit and Selenium :focus test | |
In order to show that Capybara Webkit and Selenium do not allow an element to maintain focus | |
I created this feature | |
Which anyone can try | |
@selenium | |
Scenario: Run demo page with Selenium | |
When I am on the capybara demo page | |
And I fill in "inpt" with "Test snapshot" | |
Then I should see a successful result |
Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
#!/usr/bin/env ruby | |
require "webrick" | |
=begin | |
WEBrick is a Ruby library that makes it easy to build an HTTP server with Ruby. | |
It comes with most installations of Ruby by default (it’s part of the standard library), | |
so you can usually create a basic web/HTTP server with only several lines of code. | |
The following code creates a generic WEBrick server on the local machine on port 1234, |
View the original gist: https://gist.github.com/428105
visit "/projects"
visit post_comments_path(post)
# -*- coding: utf-8 -*- | |
require 'faraday' | |
require 'faraday_middleware' | |
module Vine | |
def self.login(username = ENV['VINE_USERNAME'], password = ENV['VINE_PASSWORD']) | |
data = Vine::Client.new.login(username, password) | |
Vine::Client.new(data['key']) | |
end |
原著者: | Adrian Holovaty |
---|---|
原文: | Why I left Heroku, and notes on my new AWS setup |
金曜日、私は Heroku から Amazon Web Services(AWS) を直接使うように Soundslice を移行しました。私はこの変更ができてとても、そうとても嬉しくて、私がどうやったかということと、もし皆さんが同じような立場だったら何故それを検討すべきかということについて広く伝えたいと思います。
var Observable = (function() | |
{ | |
"use strict"; | |
/** | |
* @constructor | |
* @returns {{attach: Function, detach: Function, notify: Function}} | |
*/ | |
var constructor = function() | |
{ |
# This is a skeleton for testing models including examples of validations, callbacks, | |
# scopes, instance & class methods, associations, and more. | |
# Pick and choose what you want, as all models don't NEED to be tested at this depth. | |
# | |
# I'm always eager to hear new tips & suggestions as I'm still new to testing, | |
# so if you have any, please share! | |
# | |
# @kyletcarlson | |
# | |
# This skeleton also assumes you're using the following gems: |