Files | Admin

Notes:

Release Name: 0.5

Notes:
	The DevCreek gem enables programmers to collect and transmit metrics from their Ruby Test::Unit and RSpec test
	suites to a DevCreek server. Please visit the DevCreek site (http://devcreek.com/index.html) for more info.

== FEATURES/PROBLEMS:
  
	Supported frameworks include Test::Unit and RSpec (> 1.10).
	 
== SYNOPSIS:

	The DevCreek Ruby Gem is library that, when loaded, will automatically listen to and collect metrics from your 
	Test::Unit/RSpec unit tests. All you have to do is load the DevCreek library in your code and give it your 
	DevCreek account info so that it can transmit the metrics to the server. Here is the simplest example of how to 
	load DevCreek:
	
	--------
	#Load the devcreek gem
	require 'rubygems'
	require 'devcreek'
	
	#set your account info 
	DevCreek::Core.instance().load_from_yaml("#{ENV['HOME']}/.yoursettingsfile.devcreek.yml")  
	--------
	
	There are two ways to provide DevCreek with your account settings. The first (as shown above) is to point DevCreek to a 
	settings file. The 'enabled' attribute tells devcreek whether or not it should actually transmit the metrics that it 
	collects. The yaml file would like this:
	
	--------
	user: your_devcreek_username
	password: your_devcreek_password
	project: your_devcreek_project
	enabled: true
	--------

	The other way to provide DevCreek with your settings is via a hash. So, instead of loading a yaml file, you could
	do this:
		
	--------
	#Load the devcreek gem
	require 'rubygems'
	require 'devcreek'
	
	#set your account info 
	DevCreek::Core.instance().load(
	  :user => 'your_devcreek_username',
      :password => 'your_devcreek_password',
      :project => 'your_devcreek_project',
      :enabled => true
	)  
	--------
	
	The first method is preferrable because it allows you to keep your account settings outside of your project (and therefore 
	your source control tool).
	
	If you only have 1 test file, you can place the code to load devcreek in the test file and your done. However, most projects will
	have many test files. In this case, you need to make sure that the Ruby interpreter loads devcreek before running
	the test classes. This can be done via the Ruby '-r' option. For example, assuming your code to load devcreek is in a file
	called foo.rb, you would run your tests from the command line like this:
	
	ruby -r foo.rb test/test_*
	
	If you run your tests from a Rakefile, then you need to tell rake to include the -r option when it runs the tests (rake
	runs it's tests in a separate Ruby process). You can do this pretty easily in your Rakefile, like so;
	
	--------
	require 'rake/testtask'
	Rake::TestTask.new('all_tests') do |t|
	  t.ruby_opts = ['-r foo.rb']
	  t.test_files = ['test/test_*.rb']
	end
	--------


Changes: == 0.1 / 2007-12-02 * Beta Release * Initial release of DevCreek Ruby gem. Support for Test::Unit framework. == 0.2 / 2007-12-07 * Small change to the documentation. Add logging functionality. == 0.3 / 2007-12-20 * Added support for rspec. Documentation changes. == 0.4 / 2008-01-02 * DevCreek gem now compresses it's payload and uses basic authentication over https. == 0.5 / 2008-01-17 * This release includes improvements to the precision of the timing metrics.