我正在关注 Mhartl Ruby on Rails 教程并开始使用 Rspec。我想知道是否有一种方法可以修复我认为在输出到 cmd 时未正确编码的行尾字符,例如:←[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