Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
We need to guess the HTML encoding here otherwise some tests fail. ``` Failures: 1) Readability images should show one image, but outside of the best candidate Failure/Error: @input = @input.gsub(REGEXES[:replaceBrsRe], '</p><p>') ArgumentError: invalid byte sequence in UTF-8 # ./lib/readability.rb:51:in `gsub' # ./lib/readability.rb:51:in `initialize' # ./spec/readability_spec.rb:80:in `new' # ./spec/readability_spec.rb:80:in `block (3 levels) in <top (required)>' 2) Readability the cant_read.html fixture should work on the cant_read.html fixture with some allowed tags Failure/Error: @input = @input.gsub(REGEXES[:replaceBrsRe], '</p><p>') ArgumentError: invalid byte sequence in UTF-8 # ./lib/readability.rb:51:in `gsub' # ./lib/readability.rb:51:in `initialize' # ./spec/readability_spec.rb:555:in `new' # ./spec/readability_spec.rb:555:in `block (3 levels) in <top (required)>' ``` Fixes #87 It also adds the latest Ruby 3 version to CI to test for these sort of bugs regularly.
- Loading branch information