{"id":14955593,"url":"https://github.com/vasfed/routes_coverage","last_synced_at":"2025-10-08T17:11:22.764Z","repository":{"id":20819825,"uuid":"91007875","full_name":"Vasfed/routes_coverage","owner":"Vasfed","description":"Routes coverage for rails request/integration/capybara tests","archived":false,"fork":false,"pushed_at":"2022-09-09T14:46:26.000Z","size":379,"stargazers_count":16,"open_issues_count":2,"forks_count":3,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-01T18:38:24.397Z","etag":null,"topics":["coverage","coverage-report","coverage-status","minitest","rails","rails4","rails5","routes-coverage","routing","rspec","ruby","testing"],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Vasfed.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-05-11T17:48:31.000Z","updated_at":"2023-05-17T00:17:22.000Z","dependencies_parsed_at":"2022-07-25T08:02:05.293Z","dependency_job_id":null,"html_url":"https://github.com/Vasfed/routes_coverage","commit_stats":null,"previous_names":[],"tags_count":20,"template":false,"template_full_name":null,"purl":"pkg:github/Vasfed/routes_coverage","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Vasfed%2Froutes_coverage","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Vasfed%2Froutes_coverage/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Vasfed%2Froutes_coverage/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Vasfed%2Froutes_coverage/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Vasfed","download_url":"https://codeload.github.com/Vasfed/routes_coverage/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Vasfed%2Froutes_coverage/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278981518,"owners_count":26079640,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-08T02:00:06.501Z","response_time":56,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["coverage","coverage-report","coverage-status","minitest","rails","rails4","rails5","routes-coverage","routing","rspec","ruby","testing"],"created_at":"2024-09-24T13:11:25.358Z","updated_at":"2025-10-08T17:11:22.747Z","avatar_url":"https://github.com/Vasfed.png","language":"Ruby","readme":"# RoutesCoverage\n[![Gem Version](https://badge.fury.io/rb/routes_coverage.svg)](https://badge.fury.io/rb/routes_coverage)\n\n\nSometimes you need to know which routes are covered by your rails test suite.\n\n![Html output example](/assets/html_output_screenshot.png?raw=true \"Html Output example\")\n\n\n## Installation\n\nAdd this line to your application's Gemfile:\n\n```ruby\ngem 'routes_coverage', group: :test\n```\n\nAnd then execute:\n\n    $ bundle\n\nOr install it yourself as:\n\n    $ gem install routes_coverage\n\n## Usage\n\nInstall the gem and run your tests, then open generated report file `coverage/routes.html`.\n\n\n### Configuration\n\nBy default html report with no groupping is generated. If you need more funtionality - options in `RoutesCoverage.settings` or rspec's `config.routes_coverage`:\n\n```ruby\nRSpec.configure do |config|\n  config.routes_coverage.perform_report = ENV['ROUTES_COVERAGE'] # only generate report if env var is set\n\n  config.routes_coverage.exclude_put_fallbacks = true # exclude non-hit PUT-requests where a matching PATCH exists\n  config.routes_coverage.include_from_controller_tests = true # include results from controller tests\n  config.routes_coverage.exclude_patterns \u003c\u003c %r{PATCH /reqs}   # excludes all requests matching regex\n  config.routes_coverage.exclude_namespaces \u003c\u003c 'somenamespace' # excludes /somenamespace/*\n\n  config.routes_coverage.groups[\"Some Route group title\"] = %r{^/somespace/}\n  config.routes_coverage.groups[\"Subdomain\"] = { constraints: { subdomain: 'some_subdomain' }, path: '/' }\n  config.routes_coverage.groups[\"Admin\"] = Regexp.union([\n    %r{^/admin/},\n    %r{^/secret_place/},\n  ])\n\n  config.routes_coverage.format = :html # html is default, others are :full_text and :summary_text, or your custom formatter class\n\n  config.routes_coverage.minimum_coverage = 80 # %, your coverage goal\n  config.routes_coverage.round_precision = 0   # just round to whole percents\nend\n```\nExcluded routes do not show in pending, but are shown if they're hit.\n\nIf rspec is not your choice - use\n\n```ruby\nRoutesCoverage.configure do |config|\n  config.format = :full_text\n  # ...\nend\n```\n\nor\n\n```ruby\nRoutesCoverage.settings.format = :full_text\n```\n\nNote that coverage from `include_from_controller_tests` (disabled by default) is not a true routes coverage.\nRounting is not tested in controller tests (which are deprecated in Rails 5),\nbut sometimes you may already have a lot of controller tests and an intent to improve green-path/business level coverage\n\n## Development\n\nAfter checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.\n\nTo install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).\n\nTo run tests against different rails versions use `appraisal rake`\n\n## Contributing\n\nBug reports and pull requests are welcome on GitHub at https://github.com/Vasfed/routes_coverage.\n\n\n## License\n\nThe gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvasfed%2Froutes_coverage","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvasfed%2Froutes_coverage","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvasfed%2Froutes_coverage/lists"}