🧛♂️
This file contains hidden or 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
| # 1.position_suffix => "st" | |
| # 2.position_suffix => "nd" | |
| # 3.position_suffix => "rd" | |
| # 4.position_suffix => "th" | |
| # 11.position_suffix => "th" | |
| # 21.position_suffix => "st" | |
| # 345678.position_suffix => "th" | |
| class Integer | |
| def position_suffix |
This file contains hidden or 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
| =begin | |
| Copyright (c) 2011, Nathaniel Ritmeyer | |
| All rights reserved. | |
| Redistribution and use in source and binary forms, with or without | |
| modification, are permitted provided that the following conditions are met: | |
| 1. Redistributions of source code must retain the above copyright notice, | |
| this list of conditions and the following disclaimer. |
This file contains hidden or 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
| #cucumber -f TestManagement::TagLogic -o /dev/null | |
| module TestManagement | |
| class TagLogic | |
| #leave this alone... | |
| def initialize(step_mother, io, options) | |
| @old_tags = [] | |
| end | |
| #leave this alone too... |
This file contains hidden or 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
| require 'rest-client' | |
| class Net::HTTP::Purge < Net::HTTPRequest | |
| METHOD = 'PURGE' | |
| REQUEST_HAS_BODY = false | |
| RESPONSE_HAS_BODY = true | |
| end | |
| module RestClient | |
| def self.purge(url, headers={}, &block) |
This file contains hidden or 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
| public void reset() | |
| { | |
| currentCount = 0; | |
| } |
This file contains hidden or 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 Counter | |
| { | |
| public class Counter | |
| { | |
| private int currentCount; | |
| public Counter() | |
| { | |
| currentCount = 0; | |
| } |
This file contains hidden or 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 Counter | |
| { | |
| public class Counter | |
| { | |
| private int currentCount; | |
| public Counter() | |
| { | |
| currentCount = 0; | |
| } |
This file contains hidden or 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
| require 'rubygems' | |
| require 'rspec/core/rake_task' | |
| require 'cucumber/rake/task' | |
| include Rake::DSL | |
| desc "Acceptance Tests" | |
| RSpec::Core::RakeTask.new do |t| | |
| t.pattern = "spec/**/*_spec.rb" | |
| end |
This file contains hidden or 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
| class RSpec::Core::Example | |
| def passed? | |
| @exception.nil? | |
| end | |
| def failed? | |
| !passed? | |
| end | |
| end |
This file contains hidden or 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
| /* | |
| Create a console app, add references to the various white libraries and use the following as a template for operating the Open Dialog window | |
| Get the white binaries from here: http://white.codeplex.com/ | |
| */ | |
| using System.Collections.Generic; | |
| using System.Linq; | |
| using System.Windows.Automation; | |
| using White.Core; | |
| using White.Core.UIItems; |