Skip to content

Conversation

@ericfirth
Copy link

This fixes the error on #49

Removing the monkey patch entirely lead to the following error

/Users/eric.firth/.rbenv/versions/3.0.4/bin/ruby -I/Users/eric.firth/.rbenv/versions/3.0.4/lib/ruby/gems/3.0.0/gems/rspec-core-3.12.2/lib:/Users/eric.firth/.rbenv/versions/3.0.4/lib/ruby/gems/3.0.0/gems/rspec-support-3.12.1/lib /Users/eric.firth/.rbenv/versions/3.0.4/lib/ruby/gems/3.0.0/gems/rspec-core-3.12.2/exe/rspec --pattern spec/\*\*\{,/\*/\*\*\}/\*_spec.rb
...........F...........................................................

Failures:

  1) PostRank::URI normalize cleans whitespace in PostRank::URIs
     Failure/Error: expect(n('http://igvita.com/a/../?  ')).to eq(igvita)

       expected: "http://igvita.com/"
            got: "http://igvita.com/?%20%20"

       (compared using ==)
     # ./spec/postrank-uri_spec.rb:77:in `block (3 levels) in <top (required)>'

Finished in 0.13964 seconds (files took 0.29346 seconds to load)
71 examples, 1 failure

Failed examples:

rspec ./spec/postrank-uri_spec.rb:76 # PostRank::URI normalize cleans whitespace in PostRank::URIs

So I split on whitespace and took the first item. I initially tried just stripping the URI as a string, but then got

     Failure/Error: expect(n('http://igvita.com/a/../? #test')).to eq(igvita)

       expected: "http://igvita.com/"
            got: "http://igvita.com/?%20"

Happy to make any changes needed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant