Skip to content

Instantly share code, notes, and snippets.

View Jirapong's full-sized avatar

Jirapong Nanta Jirapong

View GitHub Profile
require 'active_record/connection_adapters/abstract_adapter'
require 'mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'
require 'System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'
module System
class DBNull
def nil?
true
end
end
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<configSections>
<section name="microsoft.scripting" type="Microsoft.Scripting.Hosting.Configuration.Section, Microsoft.Scripting, Version=0.9.5.1, Culture=neutral, PublicKeyToken=null" requirePermission="false" />
</configSections>
<microsoft.scripting>
<languages>
<language names="IronPython;Python;py" extensions=".py" displayName="IronPython 2.6 Alpha" type="IronPython.Runtime.PythonContext, IronPython, Version=2.6.0.1, Culture=neutral, PublicKeyToken=null" />
<language names="IronRuby;Ruby;rb" extensions=".rb" displayName="IronRuby 0.3" type="IronRuby.Runtime.RubyContext, IronRuby, Version=0.3.0.0, Culture=neutral, PublicKeyToken=null" />
describe "Widget#foo" do
it "does something" do
# This should be the functionality specs specific to the semantics of the method
Widget.new.foo.should == "do something"
end
end
# This captures the "type signature" of the method. Here are recipes for corner cases that you might forget.
# Note that the examples are not self-consistent by design. Only some of them might apply to any given method.
# However, the goal below is to include the union of all possible examples so that you can cut and paste