diff --git a/lib/lonely_coder/mailbox.rb b/lib/lonely_coder/mailbox.rb index 5935c50..b8c55ef 100644 --- a/lib/lonely_coder/mailbox.rb +++ b/lib/lonely_coder/mailbox.rb @@ -103,7 +103,7 @@ def initialize(browser) @browser = browser end - def useage + def usage html = @browser.get('/messages') current, max = html.search('p.fullness').text.match(/([\d]+) of ([\d]+)/).captures diff --git a/lib/lonely_coder/search.rb b/lib/lonely_coder/search.rb index 23b5d32..c416ed2 100644 --- a/lib/lonely_coder/search.rb +++ b/lib/lonely_coder/search.rb @@ -50,7 +50,7 @@ def search(options={}) Search.new(options, @browser) end - # The OKCupid search object. Stores filters and query options and a results set. Correct useage is to obtain + # The OKCupid search object. Stores filters and query options and a results set. Correct usage is to obtain # and instance of this class by using OKCupid#search(options). # @see OKCupid#search class Search diff --git a/spec/mailbox_spec.rb b/spec/mailbox_spec.rb index 06b3081..4865d55 100644 --- a/spec/mailbox_spec.rb +++ b/spec/mailbox_spec.rb @@ -5,7 +5,7 @@ VCR.use_cassette('loading_mailbox', :erb => {username: ENV['OKC_USERNAME'], password: ENV['OKC_PASSWORD']}) do okc = OKCupid.new(ENV['OKC_USERNAME'], ENV['OKC_PASSWORD']) @mailbox = okc.mailbox - @mailbox.useage.should == { + @mailbox.usage.should == { current: 233, max: 300 }