{"id":16925427,"url":"https://github.com/alejandrodevs/shoulda_routing","last_synced_at":"2025-03-21T01:28:38.994Z","repository":{"id":10216733,"uuid":"12313723","full_name":"alejandrodevs/shoulda_routing","owner":"alejandrodevs","description":"A simple DSL to test rails routes.","archived":false,"fork":false,"pushed_at":"2017-06-14T16:53:13.000Z","size":85,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-06T12:52:52.114Z","etag":null,"topics":[],"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/alejandrodevs.png","metadata":{"files":{"readme":"README.md","changelog":null,"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":"2013-08-23T03:33:14.000Z","updated_at":"2016-03-30T21:25:13.000Z","dependencies_parsed_at":"2022-08-21T01:20:48.235Z","dependency_job_id":null,"html_url":"https://github.com/alejandrodevs/shoulda_routing","commit_stats":null,"previous_names":["alejandrogutierrez/shoulda_routing"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alejandrodevs%2Fshoulda_routing","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alejandrodevs%2Fshoulda_routing/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alejandrodevs%2Fshoulda_routing/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alejandrodevs%2Fshoulda_routing/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/alejandrodevs","download_url":"https://codeload.github.com/alejandrodevs/shoulda_routing/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244720477,"owners_count":20498801,"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","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":[],"created_at":"2024-10-13T20:10:37.030Z","updated_at":"2025-03-21T01:28:38.972Z","avatar_url":"https://github.com/alejandrodevs.png","language":"Ruby","readme":"# ShouldaRouting\n\nThis gem aims to provide a simple DSL that looks like the rails routes DSL that is used in the routes.rb file.\nThis requires the [RSpec](https://github.com/rspec/rspec-rails) testing framework.\n\n## Important\n\nThis gem is deprecated because this was created by me when I didn't know\nwhat and how to test applications. It's not longer maintained and I\nrecommend you not to use it.\n\n## Installation\n\nAdd this line to your application's Gemfile:\n\n    gem 'shoulda_routing'\n\nAnd then execute:\n\n    $ bundle install\n\nOr install it yourself as:\n\n    $ gem install shoulda_routing\n\n## Basic usage\n\nIn your routes.rb file:\n\n```ruby\nYourApp::Application.routes.draw do\n  namespace :admin do\n    resources :users\n    resources :posts, only: [:index, :show]\n\n    namespace :mobile do\n      resources :users\n      resources :parents, controller: :users\n    end\n  end\n\n  resources :users, except: :destroy do\n    resources :posts, :comments\n  end\nend\n```\n\nIn your routing_spec.rb file:\n\n```ruby\nrequire 'spec_helper'\n\ndescribe \"Routes\" do\n  namespace :admin do\n    resources :users\n    resources :posts, only: [:index, :show]\n\n    namespace :mobile do\n      resources :users\n      resources :parents, controller: :users\n    end\n  end\n\n  resources :users, except: :destroy do\n    resources :posts, :comments\n  end\nend\n```\nThis will generate the necessary tests for all rails routes above.\n\n## TO-DO\n\n* Support member and collection routes.\n* Support single resources (get, post, put, delete) actions.\n\n## Testing\n\nTo run the test suite you should run the default rake task:\n\n    $ bundle exec rake\n\nTo run the unit tests:\n\n    $ bundle exec rake spec:unit\n\nTo run the integration tests:\n\n    $ bundle exec cucumber\n\n## Contributing\n\n1. Fork it\n2. Create your feature branch (`git checkout -b my-new-feature`)\n3. Commit your changes (`git commit -am 'Add some feature'`)\n4. Push to the branch (`git push origin my-new-feature`)\n5. Create new Pull Request\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falejandrodevs%2Fshoulda_routing","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falejandrodevs%2Fshoulda_routing","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falejandrodevs%2Fshoulda_routing/lists"}