Skip to content

Instantly share code, notes, and snippets.

class TestMailer
def load_settings(site)
options = YAML.load_file("#{RAILS_ROOT}/config/test.yml")[RAILS_ENV][site]
@@smtp_settings = {
:address => options["address"],
:port => options["port"],
:domain => options["domain"],
:authentication => options["authentication"],
:user_name => options["user_name"],
default: -r features/support/env.rb -r features/support/plain.rb -r features/step_definitions features/plain
selenium: -r features/support/env.rb -r features/support/enhanced.rb -r features/step_definitions features/enhanced
default: -r features/support/env.rb -r features/support/plain.rb -r features/step_definitions features/plain
selenium: -r features/support/env.rb -r features/support/enhanced.rb -r features/step_definitions features/enhanced
@jasonong
jasonong / x
Created July 13, 2009 02:02 — forked from zlu/x
CmdUtils.CreateCommand({
names: ["rails"],
icon: "http://rubyonrails.org/favicon.ico",
description: "Search rails documentation",
help: "Type a rails class or method.",
author: {name: "Jason Ong", email: "velvetpd@gmail.com"},
license: "GPL",
homepage: "",
arguments: [{role: "object", nountype: noun_arb_text, label: "class or method"}],
preview: function preview(pblock, args) {
//General function for retrieving verses
function verseQuery ( apiParams, callback) {
var apiUrl = "http://www.esvapi.org/v2/rest/passageQuery?";
jQuery.ajax({
type: "GET",
url: apiUrl,
dataType: "html",
data: apiParams,
error: function() {
CmdUtils.CreateCommand({
names: ["objectliteral"],
icon: "http://www.blogger.com/favicon.ico",
description: "Shortcut to my blog.",
help: "list, create or search",
author: {name: "Jason Ong", email: "velvetpd@gmail.com"},
license: "GPL",
homepage: "http://objectliteral.blogspot.com",
arguments: [{role: 'object', nountype: noun_arb_text}],
urls: {
namespace :unittest do
task *[:tag, (0..100).map {|i| "t#{i}".to_sym }].flatten do |t, args|
args.each do |key, value|
Dir[File.join(RAILS_ROOT, 'test', 'unit', '*.rb')].each do |file|
File.open(file,'r') do |fh|
tags = fh.grep(/\~(\S+)/).map do |t|
t.strip!
@jasonong
jasonong / srb14052011
Created May 12, 2011 03:04
Show notes from Singapore Ruby Brigade meet up on 11th May 2011
== Meetup ==
Date: 11th May 2011
Time: 7:30pm
Venue: HackerspaceSG, 70A Bussorah Street
== Food and Beer ==
Many thanks to Carl from Pivotal Labs for providing delicious Arabic snacks and ice cold Wychcrafts, Asahis and Hoegardens from Mabuk Monkey.
And also special thanks to Meng for serving us flame thrown carnival.
@jasonong
jasonong / terminology20110524
Created May 25, 2011 15:41
Show notes from Terminology meet up on 24th May 2011
Date: 25th May 2011
Time: 7:30pm
Venue: HackerspaceSG, 70A Bussorah Street
# Patrick:
~/.bashrc
http://haller.ws/projects/bash/
# Ivan:
http://en.wikipedia.org/wiki/The_Mother_of_All_Demos
@jasonong
jasonong / gist:1002660
Created June 1, 2011 16:13
Show notes from Singapore Ruby Brigade meet up on 1st June 2011
# Talks
* SF/SV communities - Aihui
* Game design with verbs - Matthew Weise
# Links
* http://bit.ly/SiliconValleyStartupScene
* http://gambit.mit.edu/
* http://www.flickr.com/photos/elfgoh/sets/72157626860409700/show/