Distributed testing for ruby with centralized management
Ruby HTML Other
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
bin
lib
spec
tests/end_to_end
.gitignore
.ruby-version
.travis.yml
Gemfile
Gemfile.lock
README.md
Rakefile
architecture.md
daemon_with_upstart_and_rvm.md
docker-compose.yml
gorgon-done-screenshot.png
gorgon.gemspec
gorgon.json.sample
gorgon_listener.json.sample
gorgon_secret.json.sample
rsync_transport.md
tutorial.md updates RabbitMQ installation instructions May 26, 2016

README.md

Gorgon Build Status Gem Version Code Climate

About

Gorgon provides a method for distributing the workload of running ruby test suites. It relies on amqp for message passing, and rsync for the synchronization of source code.

Installing Gorgon

This tutorial explains how to install gorgon in a sample app.

Installing listener as a Daemon process (Ubuntu 9.10 or later)

  1. run gorgon install_listener from the directory where gorgon.json is
  2. run gorgon ping to check if the listener is running

Gotchas

  • if you get cannot load such file -- qrack/qrack (LoadError), just add gem 'gorgon', '~> 0.8.4' , :group => :remote_test to your Gemfile, and run tests using bundle exec gorgon
  • If gorgon install_listener didn't work for you, you can try these steps

Also note that the steps in the tutorial are not meant to work on every project, they will only give you initial settings. You will probably have to modify the following files:

  • gorgon.json
  • gorgon_secret.json
  • {test, spec}/gorgon_callbacks/gorgon_callbacks.rb
  • gorgon_listener.json (located in your project root or in ~/.gorgon/)

If you modify ~/.gorgon/gorgon_listener.json, make sure you restart the listener.

Configuration

gorgon.json

This file contains project-specific settings for gorgon, such as:

  • The connection information for AMQP
  • The connection information for File Server
  • Information about how clients can rsync the working directory (optional). See more info here
  • Files that can be excluded by rsync
  • Callback file containing Ruby code to be used as callbacks
  • A glob for generating the list of test files
  • The file used for Originator's logs

See gorgon.json example for an example file.

gorgon_secret.json (optional)

This optional file contains sensitive information such as passwords that cannot be put in gorgon.json.

See gorgon_secret.json example for an example file.

gorgon_listener.json

This file contains the listener-specific settings, such as:

  • The connection information for AMQP
  • How many worker slots are provided by this listener
  • The file used for logs

See gorgon_listener.json example for more details.

Contributing

Read overview architecture

Running all tests

  • rake

Running only specs

  • rspec spec

NOTE: The end to end tests will fail if we do not prepare our system to run them.

Running end to end specs

  1. cd tests/end_to_end
  2. Run /usr/local/sbin/rabbitmq-server in the background
  3. bundle install
  4. gorgon listen
  5. In a new tab/window, run rspec spec

Credits

Gorgon is maintained by:

  • Justin Fitzsimmons
  • Arturo Pie

Gorgon is funded by Nulogy Corp. Thank you to all the contributors.