Setting up a development environment for Buildr plugin

Content copied from


Basic setup:

Specs setup:

unless defined?(SpecHelpers)
  module SandboxHook

    def SandboxHook.included(spec_helpers)
      # For testing we use the gem requirements specified on the buildr4osgi.gemspec
      spec = Gem::Specification.load(File.expand_path('../my.gemspec', File.dirname(__FILE__)))
      spec.dependencies.each { |dep| gem, dep.requirement.to_s }
      # Make sure to load from these paths first, we don't want to load any
      # code from Gem library.
      $LOAD_PATH.unshift File.expand_path('../lib', File.dirname(__FILE__))
      require 'mymodule'
  require File.join(File.dirname(__FILE__), "/../buildr/spec/spec_helpers.rb")


You're done.

Try rake -T to see the buildr tasks available, use rake coverage to run tests and rake failed when you need to insist.