Joe,
Here is the solution I decided to go with, for now:
describe Collaborator do
describe "class_methods" do
subject {Collaborator}
it { should respond_to(:search_ldap).with(1).argument }
it "should format the search term" do
subject.prepare_search_term("Bob").should == "bob
On Tue, Jun 21, 2011 at 17:00, Jed Schneider wrote:
> given I have the following with the internal assignments to filter and ldap:
> class Collaborator
> def self.search_ldap(term)
> last_name = term.strip.split(/[, ]/).first.downcase
> filter = Net::LDAP::Filter.eq('surName', last_name)