This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
it "should authenticate with matching email and password" do | |
user = Factory(:user, :email => "[email protected]", :plain_password => "secret") | |
User.authenticate("[email protected]", "secret").should == user | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Salesforce | |
class LeadConvert | |
include DataMapper::Resource | |
# set the adapter | |
def self.default_repository_name | |
:salesforce | |
end | |
# standard fields |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ============================================================================= | |
# ENVIRONMENTS | |
# ============================================================================= | |
task :dev do | |
desc "Deploys to the development server specifically" | |
puts "*** Deploying to the \033[1;42m DEVELOPMENT \033[0m server!" | |
set :rails_env, "development" | |
role :web, "dev.#{domain}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
%: rvm install ree-1.8.7-head | |
info: Installing Ruby from source to: /usr/local/rvm/rubies/ree-1.8.7-head | |
info: Pulling from git://github.com/FooBarWidget/rubyenterpriseedition187.git, this may take a while depending on your connection... | |
From git://github.com/FooBarWidget/rubyenterpriseedition187 | |
* branch master -> FETCH_HEAD | |
Already up-to-date. | |
info: Copying from repo to src path... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[2010-06-17 22:16:58] ./configure --prefix=/usr/local/rvm/rubies/ree-1.8.7-head --dont-install-useful-gems | |
configure: error: unrecognized option: --dont-install-useful-gems | |
Try `./configure --help' for more information. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# CIJOE | |
# setup Continuous Integration | |
`git config --remove-section cijoe` | |
`git config --add cijoe.runner "RAILS_ENV=test rake -s test"` | |
`git config --add cijoe.branch development` | |
`git config --add cijoe.buildallfile tmp/cijoe.txt` | |
# copy build-failed hook | |
`cp lib/hooks/* .git/hooks && chmod +x .git/hooks/*` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# CIJOE | |
# | |
# Put this file to $PROJECT/.git/hooks/ for after pull changes. | |
# | |
rm -rf /data/Woople_CI/current/config/database.yml | |
ln -s /data/Woople_CI/shared/config/database.yml /data/Woople_CI/current/config/database.yml | |
rake db:create:all |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# CIJOE | |
# | |
# Put this file to $PROJECT/.git/hooks/ for email notifications. | |
# | |
# Do not forget: chmod +x build-failed | |
RAILS_ENV=staging rake woople:continuous_integration RECIPIENT=[your_email_address] STATUS="Failed" SHA=$SHA AUTHOR=$AUTHOR MESSAGE=$MESSAGE OUTPUT=$OUTPUT |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace :woople do | |
desc "Continuous Integration Notification" | |
task :continuous_integration => :environment do | |
# CIJOE | |
# inline class | |
class CIMailer < MadMimiMailer | |
def mimi_blank_template(recipient, subject, message) | |
from "Woople Notifications <notifications@#{MAIN_HOST}>" | |
recipients recipient |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# CIJOE | |
# Example CI Joe rackup config. Drop a cijoe.ru file | |
# in your projects direct | |
require 'cijoe' | |
# set the $project_path global | |
$project_path = `pwd`.gsub(/\n/, '') | |
# setup middleware | |
use Rack::CommonLogger |
OlderNewer