Small Eigen Collider produces random ruby programs in order to compare the results under different ruby implementations.
HOW IT (KIND OF) WORKS:
Random ruby programs are created by starting off with a set of objects and a set of method names. A receiver is selected at random from the set of objects, and then a method name is randomly selected, then a random number of random parameter objects. A block is also included in case the method chosen requires one.
Once everything is chosen, the code
receiver_object.send(method, *parameter_objects, &block)
is run, and the inputs and the results are logged.
HOW TO USE IT:
To compare different ruby implementations, run Small Eigen Collider under those implementations and look at the differences.
During an initial run, unfiltered_tasks.yml is created, listing the programs (tasks) the Small Eigen Collider is going to run. Then it runs the tasks. It then applies a filter, rejecting those that caused an exception, or ones that are known to produce different results under different implementations. The tasks are saved to tasks.yml, and a log file showing the results of the filtered tasks.
During subsequent runs, the tasks listed in tasks.yml are run, and a log file specific to the implementation and patchlevel of the ruby implementation is produced, such as ruby_1.9.2_53_output.txt .
Random ruby programs are produced. Some of these programs may harm your computer, either by affecting performance or by deleting data.
If you can understand this, put a file called “i_understand_the_risks.txt” in the directory you're running this from.
Currently not a gem
(The MIT License)
Copyright © 2010 Andrew Grimm.
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the 'Software'), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.