What object-oriented programming advice is this code violating?
def check_for_overheating(system_monitor)
if system_monitor.temperature > 100
system_monitor.sound_alarms
end
end
require_relative "test_helper" | |
require "open-uri" | |
require "net/http" | |
class EmojiTest < Blog::Test | |
def test_no_emoji | |
posts.each do |post| | |
content = File.read(post) | |
refute_match /:[a-zA-Z0-9_]+:/, content, |
TL;DR
Create a backup:
pg_dumpall > mybackup.sql
Perform the upgrade:
sudo pg_dropcluster 9.4 main --stop
namespace :qc do | |
desc "start queue classic" | |
task :start do | |
run "nohup sh #{current_path}/qc_worker start > /dev/null 2>&1 &" | |
end | |
desc "stop queue classic" | |
task :stop do | |
run "sh #{current_path}/qc_worker stop" | |
end |
This is similar to the built-in Cucumber JSON formatter except it expands scenario outlines so each row is reported with its result. Thus, scenario outlines appear similar to regular scenarios in the JSON output.
This supports regular mode and "--expand" mode. In both cases, scenario outline tables are expanded (however the underlying logic for doing the expansion varies greatly).
CREATE TEXT SEARCH CONFIGURATION fr ( COPY = french ); | |
ALTER TEXT SEARCH CONFIGURATION fr ALTER MAPPING | |
FOR hword, hword_part, word WITH unaccent, french_stem; | |
CREATE TEXT SEARCH CONFIGURATION en ( COPY = english ); | |
ALTER TEXT SEARCH CONFIGURATION en ALTER MAPPING | |
FOR hword, hword_part, word WITH unaccent, english_stem; | |
CREATE TEXT SEARCH CONFIGURATION de ( COPY = german ); | |
ALTER TEXT SEARCH CONFIGURATION de ALTER MAPPING |
require 'bundler/capistrano' | |
set :application, "net" | |
set :repository, "[email protected]:net.git" | |
set :scm, :git | |
set :default_environment, { | |
'PATH' => "$HOME/.rbenv/shims:$HOME/.rbenv/bin:$PATH" | |
} |
#!/usr/bin/env bash | |
curl https://s3.amazonaws.com/heroku-jvm-buildpack-vi/vim-7.3.tar.gz --output vim.tar.gz | |
mkdir vim && tar xzvf vim.tar.gz -C vim | |
export PATH=$PATH:/app/vim/bin |
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)