RubyGems Navigation menu

quacks-like 1.0.0

QuacksLike is a module for RSpec to add matchers that test if an object is fully duck-typed to pretend to be another class. This kind of thing is really only necessary when passing such an object as the return value in an API where you don't know exactly how it will be consumed, but it needs to "quack like an Array" or something. It does its job by checking every instance method in the class that the target object needs to "quack like" and makes sure the target both responds to that method name and that the arity of the method is appropriate.

Versions:

  1. 1.0.0 - September 11, 2010 (5 KB)

Authors:

  • Michael H Buselli

Owners:

0a62a70dce71f7360b27143d78f7b58c

Sha 256 checksum:

8117980e5695b28a72c123b868e977275bd64f72bbae18b83d512408226c2098

Total downloads 1,479

For this version 1,479

Required Ruby Version: None

Licenses:

N/A

Gemfile:
= Copy to clipboard Copied!

install:
= Copy to clipboard Copied!

Links: