Contours of San Francisco overlayed over OpenStreeMap vector tiles using code from mbostock's vector tiles with multiple layers example. View the hi-res file
See gist for code used to generate contours.
link_to | |
image_tag | |
link_to image_tag(“rails.png”, alt: “Rails logo”), “#” | |
<%= debug(params) if Rails.env.development %> | |
Because we used theimage_tag helper in Listing 5.2, Rails will automatically find any images in theapp/assets/images/ directory using the asset pipeline (Section 5.2). |
```ruby | |
assert_no_difference 'User.count' do | |
post users_path, user: { name: "", | |
email: "user@invalid", | |
password: "foo", | |
password_confirmation: "bar" } | |
end | |
``` | |
Here we’ve included the params[:user] hash expected by User.new in the create action (Listing 7.24). By wrapping the post in the assert_no_difference method with the string argument ’User.count’, we arrange for a comparison between User.count before and after the contents of the assert_no_difference block. This is equivalent to recording the user count, posting the data, and verifying that the count is the same: |
```ruby | |
user && user.authenticate(:password) | |
``` |
flash.now, which is specifically designed for displaying flash messages on rendered pages. Unlike the contents of flash, the contents of flash.now disappear as soon as there is an additional request, |
# This scripts merges subtitles (if present) and transcodes video files | |
# to H.264 mp4 video files with similar quality level. | |
# This will be applied to all video files found under the directory passed | |
# as an argument to the script or the current working directory otherwise. | |
# The script will also check if the ffmpeg binaries are present and located | |
# in unrestricted directory. It will also check for the presence of fonts | |
# configuration file and copy it to the right place if they are absent. | |
# | |
# This code is free software: you can redistribute it and/or modify it under | |
# the terms of the GNU Lesser General Public License as published by the Free |
Contours of San Francisco overlayed over OpenStreeMap vector tiles using code from mbostock's vector tiles with multiple layers example. View the hi-res file
See gist for code used to generate contours.
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta name="description" content="redex react todo list example add todo"> | |
<script src="https://fb.me/react-0.14.7.min.js"></script> | |
<script src="https://fb.me/react-dom-0.14.7.min.js"></script> | |
<script src="https://cdnjs.cloudflare.com/ajax/libs/redux/3.0.4/redux.js"></script> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width"> | |
<title>JS Bin</title> |
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta name="description" content="redux react todo list example <filter todos>"> | |
<script src="https://fb.me/react-0.14.7.min.js"></script> | |
<script src="https://fb.me/react-dom-0.14.7.min.js"></script> | |
<script src="https://cdnjs.cloudflare.com/ajax/libs/redux/3.0.4/redux.js"></script> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width"> | |
<title>JS Bin</title> |
require 'test_helper' | |
# testing rake task app:awesome_report | |
# defined in file lib/tasks/app/awesome_report.rake | |
describe 'App::AwesomeReportTaskTest' do | |
it 'generates the awesomeness report' do | |
subject.invoke | |
assert File.exists?('awesomeness_report.csv') | |
end |
Country | CountryCode | Currency | Code | |
---|---|---|---|---|
New Zealand | NZ | New Zealand Dollars | NZD | |
Cook Islands | CK | New Zealand Dollars | NZD | |
Niue | NU | New Zealand Dollars | NZD | |
Pitcairn | PN | New Zealand Dollars | NZD | |
Tokelau | TK | New Zealand Dollars | NZD | |
Australian | AU | Australian Dollars | AUD | |
Christmas Island | CX | Australian Dollars | AUD | |
Cocos (Keeling) Islands | CC | Australian Dollars | AUD | |
Heard and Mc Donald Islands | HM | Australian Dollars | AUD |