{"id":13586845,"url":"https://github.com/sandro/specjour","last_synced_at":"2025-04-04T09:09:40.585Z","repository":{"id":669754,"uuid":"523826","full_name":"sandro/specjour","owner":"sandro","description":"distributed rspec \u0026 cucumber via bonjour","archived":false,"fork":false,"pushed_at":"2021-01-06T07:14:03.000Z","size":676,"stargazers_count":212,"open_issues_count":12,"forks_count":31,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-03-28T08:09:02.078Z","etag":null,"topics":["bonjour","concurrent-tests","distributed-tests","rspec","ruby","test-runner","testing-tools"],"latest_commit_sha":null,"homepage":"","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/sandro.png","metadata":{"files":{"readme":"README.markdown","changelog":"History.markdown","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2010-02-18T05:29:52.000Z","updated_at":"2024-09-21T18:13:40.000Z","dependencies_parsed_at":"2022-08-03T03:15:12.802Z","dependency_job_id":null,"html_url":"https://github.com/sandro/specjour","commit_stats":null,"previous_names":[],"tags_count":57,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sandro%2Fspecjour","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sandro%2Fspecjour/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sandro%2Fspecjour/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sandro%2Fspecjour/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sandro","download_url":"https://codeload.github.com/sandro/specjour/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247149502,"owners_count":20891954,"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":["bonjour","concurrent-tests","distributed-tests","rspec","ruby","test-runner","testing-tools"],"created_at":"2024-08-01T15:05:51.298Z","updated_at":"2025-04-04T09:09:40.569Z","avatar_url":"https://github.com/sandro.png","language":"Ruby","readme":"# Specjour\n\n## Notes\n  Listener daemonized or foregrounded\n    forks a loader\n      loader should load, setsid, then exit\n        all workers then have the same sid and gid with no parent pid\n        worker pgid = 100 sid = 100\n          webkit_server\n        worker pgid = 100 sid = 100\n          webkit_server\n\n  performance.txt\n  printing informational messages\n  single specjour command starts daemon\n  interrupts\n  handle no careful_test database\n  bonjour announce project names\n  printer#project_name aliases\n\n\n## Instructions\n\n1. Start a listener on every machine in the network. `# specjour listen`\n2. Start a dispatcher. `# specjour`\n3. Say farewell to your long coffee breaks.\n\n## Installation\n    gem install specjour\n\n### Rails\nEach worker needs an isolated database. Modify the test database name in your\n`config/database.yml` to include the following environment variable (Influenced\nby [parallel\\_tests](http://github.com/grosser/parallel_tests)):\n\n    test:\n      database: project_name_test\u003c%=ENV['TEST_ENV_NUMBER']%\u003e\n\n## Give it a try\n\n  source .dev\n  bin/specjour listen -f -l\n  bin/specjour spec/\n\n\nRun `specjour` to start a dispatcher, manager, and multiple workers in the same\nterminal window.\n\n    $ cd myproject\n    $ specjour\n\n## Start a manager\nIf you wish to share your computing power with the rest of the computers in your network, run `specjour listen` to start a long running process. The next time you, or any of your co-workers run `specjour`, they'll find your machine.\n\n    $ specjour listen\n\n## Distribute the tests\nDispatch the tests among the managers in the network. Specjour checks the\n'spec' and 'features' directories for tests to send to the listening\nmanagers.\n\n    $ specjour\n\n## Supplementary\n\n### Distribute a subset of tests\nThe first parameter of the specjour command is a test directory. It defalts to\nthe current directory and searches for 'spec' and 'features' paths therein.\n\n    $ specjour spec # all rspec tests\n    $ specjour spec/models # only model tests\n    $ specjour features # all features\n\n### Custom Hooks\nSpecjour allows you to hook in to the test process on a per-machine and\nper-worker level through the before\\_fork and after\\_fork configuration blocks.\nIf the default hooks don't work for your project, they can be overridden.\n\n    # .specjour/hooks.rb\n\n    # Modify the way you use bundler\n    Specjour::Configuration.before_fork = lambda do\n      system('bundle install --without production')\n    end\n\n    # Modify your database setup\n    Specjour::Configuration.after_fork = lambda do\n      # custom database setup here\n    end\n\nA preparation hook is run when `specjour prepare` is invoked. This hook allows\nyou to run arbitrary code on all of the listening workers. By default, it\nrecreates the database on all workers.\n\n    # .specjour/hooks.rb\n\n    # Modify preparation\n    Specjour::Configuration.prepare = lambda do\n      # custom preparation code\n    end\n\n### Customize what gets rsync'd\nThe standard rsync configuration file may be too broad for your\nproject. If you find you're rsyncing gigs of extraneous data from your public\ndirectory, add an exclusion to your project's rsyncd.conf file.\n\n    $ vi workbeast/.specjour/rsyncd.conf\n\n### Listen for multiple projects\nBy default, a manager will listen to the project in the current directory. If you want to run tests for multiple projects, use the `--projects` flag.\n\n    $ specjour listen --projects bizconf workbeast # run tests for the bizconf and workbeast projects\n\n### Give your project an alias\nBy default, the dispatcher looks for managers matching the project's directory name. If you have multiple teams working on different branches of the same project you may want to isolate each specjour cluster. Give your project an alias and only listen for that alias.\n\n    ~/bizconf $ specjour listen --projects bizconf_08\n    ~/bizconf $ specjour --alias bizconf_08\n\n    ~/bizconf $ specjour listen --projects bizconf_09\n    ~/bizconf $ specjour --alias bizconf_09\n\n### Working with git\nCommit the .specjour directory but ignore the performance file. The performance\nfile constantly changes, there's no need to commit it. Specjour uses it in an\nattempt to optimize the run order; ensuring each machine gets at least one\nlong-running test.\n\n    $ cat .gitignore\n    /.specjour/performance\n\n## Compatibility\n\n* RSpec 2\n* Cucumber 0.9+\n* Rails 3\n\n## Support\n\n* [Github Wiki](https://github.com/sandro/specjour/wiki/)\n* [Github Issues](https://github.com/sandro/specjour/issues)\n\n## Hacking on Specjour\nIf you want to hack on specjour, here is how to test your changes:\n\n    source .dev\n    rake # run the test suite sanely\n    specjour # run the test suite with specjour\n\nThen if all is good, go to another app and test your changes on your test suite:\n\n    gem build specjour.gemspec\n    cd /path/to/your/project\n    gem install -l /path/to/specjour/latest.gem\n    specjour\n\n## Thanks\n\n* shayarnett - Cucumber support, pairing and other various patches\n* voxdolo - Endless support, alpha testing, various patches\n* l4rk and leshill - Removed Jeweler, added support for RSpec 2 and Cucumber 0.9+\n* testjour - Ripped off your name\n* parallel\\_tests - Inspiration\n\n## Note on Patches/Pull Requests\n\n* Fork the project.\n* `$ source .dev` to ensure you're using the local specjour binary, not the\n  rubygems version\n* Make your feature addition or bug fix.\n* Add tests for it. This is important so I don't break it in a\n  future version unintentionally.\n* Commit, do not mess with rakefile, version, or history.\n  (if you want to have your own version, that is fine but bump version in a commit by itself I can ignore when I pull)\n* Send me a pull request. Bonus points for topic branches.\n\n## Copyright\n\nCopyright (c) 2010 Sandro Turriate. See MIT\\_LICENSE for details.\n","funding_links":[],"categories":["Ruby"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsandro%2Fspecjour","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsandro%2Fspecjour","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsandro%2Fspecjour/lists"}