I am following the Mhartl Ruby on Rails tutorial and beginning to use Rspec. I was wondering if there is a way to fix what I assume are end of line characters that are not properly encoded when outputting to cmd such as: ←[0m
C:\PROGRAMMING\RailsSites\sample_app>bundle exec rspec spec/requests/static_pages_spec.rb
←[32m.←[0m←[32m.←[0m←[31mF←[0m
Failures:
1) Static Pages About page should have the content 'About Us'
←[31mFailure/Error:←[0m ←[31mvisit '/static_pages/about'←[0m
←[31mActionController::RoutingError:←[0m
←[31mNo route matches [GET] "/static_pages/about"←[0m
←[36m # ./spec/requests/static_pages_spec.rb:20:in `block (3 levels) in <top (required)>'←[0m
Finished in 3.66 seconds
←[31m3 examples, 1 failure←[0m
Failed examples:
←[31mrspec ./spec/requests/static_pages_spec.rb:19←[0m ←[36m# Static Pages About page should have the content 'About Us'←[0m
Those are the ANSI codes to colorize the text.
Pass the
--no-coloroption when you run the rspec command to disable these codes. You can also add--no-colorto your.rspecfile to make it a default option for your project.